PDA

View Full Version : Problem with User control in VC# .net



n_porkodi
April 20th, 2007, 05:03 AM
Hi All,
I'm using Visual Studio 2005 VC#. With that I've created a User control with a label and a picture box. I've included some custom properties to that user control. That's all working fine. The problem I'm facing is I need to allow user to enter "multiline" text in one of the miscellaneous properties of the user control.
Can anyone have idea about this? (Even I override "Text" property of base, it doesn't allow user to enter multiline text, as done with normal label's "Text" property)

TheColonial
April 21st, 2007, 03:58 AM
I'm not too sure as I've not done this before (and a quick google search revealed nothing), but have you thought about changing your property type to a collection/list of strings?

Templarian
April 21st, 2007, 01:05 PM
What exactly are you making multiple lines the lable box? If your using the default text, it should allow multi line already. You can't use string because I guess string isn't multi line.

Cienio
April 24th, 2007, 09:44 AM
If You need show multiline label change property AutoSize on false and set Size proberty enought big to show yuor label.