In my application I built some usercontrols, and I want to work with them in the design of visual studio.
And in many times the designer tell me that he can't deal with my usercontrol because nullreference exception or wathever.
when the application run I don't have these exceptions, because I instantiate all my data, but in design mode I don't need any data, just see the control,
How can I check if I'm in "design mode" and then when I build my control, if it's design mode I instantiate it with empty data
Thanks.