[Answering a follow-up Question]
Thank you SA for the clear explanation! But even when I do like that, how can I "DRAG" and "DROP" my custom text box onto my form? I can only create an instance of it by using code, but where is its position on my form? I have also to use code (use Location property), but is it exactly a position I want? It is too difficult to do! Plus I have about 200 such instances of my custom TextBox
and I think dragging and dropping them onto my form at design time is the easiest and the most feasible way, no other way to do that. Could you please give me more suggestions to solve my problem? Thank you so much!No, it only the easiest way to demonstrate how cool the Designer is. :-) For a serious application such style only slows you down; and the final result may never be achieved. You need to design UI more thoroughly.
Please try to use the list of my (incomplete) directions for better UI design:
GUI Apperance - C#.Net[
^],
Zom Out malfunctions when Screen resolution changes[
^],
Code behind class implementation[
^].
One important aspect here: never use absolute positioning. Always use Dock in combination with Padding and/or Margins. Do not assume fixed sizes of anything. Do not create multiple controls in one container. If there are too many, they belong to a
UserControl
or a different view. Hide controls which are not currently used — the user also does not want to see too many. This aspect is explain in one of my Solutions referenced above.
—SA