raf

raf

  • NA
  • 7
  • 1.6k

Best way to play with Form Designer

Sep 19 2011 4:36 AM
Hello,
I am working with windows form since a few days, but having some question about the good way to play with the windows form designer. If I use "external" class with object data list and I want to use use them with a ComboBox for example:

<code>
 this.comboBox1.FormattingEnabled = true;
            /*this.comboBox1.Items.AddRange(new object[] {
            "01",
            "02",
            "03"
            });
             * */
            Data myData = new Data();
            this.comboBox1.Items.AddRange(myData.m_data);
</code>
then If I add modification to the form with the Designer all my added code  is reset. Does that mean that If I insert code to the Windows Form Designer generated code I can't no more use the Designer ? or is there any secret tricks ? or is it better to not use the designer ?
thanks for you help.


Answers (6)