I have extended a ultratextbox and I like to set the control hieght to a specific height (21) when the control is created in design mode. I found an article on msdn to how to perform custom initialization for controls in design mode by overriding the InitializeNewComponent method. Is there a way to do this with the infragistics controls?
John
If I remember correctly, InitializeNewComponent is on the designer class itself and not the control. If you only ever want this to be applicable when the control is created at design-time, then I think you'd have to create your own class that derives from the UltraTextEditor's designer (UltraTextEditorDesigner) and override the InitializeNewComponent. Then you'd have to add the Designer attribute to a new derived class that you would need to create for the control itself.
If you want this to be applicable to any controls created at run-time too (or just don't care because you're not creating anything at run-time), I would think that the much simpler approach would be to override the DefaultSize property on the control.
-Matt
Matt
Do you have some sample code on how to do this?
john