I am not sure but it sounds to me like the values from your datasource are
being grabed at design time and are then being serialized into your
designer.cs file.
When user controls are displayed at design time, visual studio is creating
instances of those controls. If you are loading data durring construction of
the control the designer will see those values and serialize them into the
code DOM (Dont quote me on this, it is just what I have observed).
To see if this is happening just open up your design.cs file and see if the
data is being included in your code. If this is what is going on try moving
the code that is creating the databinding into an if statement that checks
the this.DesignMode variable.
if(!this.DesignMode){
// do databinding here.
}
Jeremy Shovan
http://www.jeremyshovan.com
"Brooke" <tb******@hotmail.comwrote in message
news:uQ**************@TK2MSFTNGP02.phx.gbl...
>I have a form with a datagridview and I set the columns that I want on the
grid. Whenever I close the form in the form designer and then open it back
up, it will pull in all of the columns from the binding source. I have to
manually edit the columns every time and remove all of the unwanted ones.
What is going on?