Objects disappearing from datagrid!

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: Mike Cooper (bidalah_at_yahoo.com)
Date: 03/03/04


Date: 3 Mar 2004 15:24:43 -0800

Hello all,

This is an extremely frustrating issue. I have a datagrid that is
populated with three different custom datagridtextboxcolumns that I
inherited they all work perfectly, while the code exist! The problem
is that every now and then, when I switch between the design view and
the code view, the instantiating code vanishes. Specifically, the
instantiating code like the following:

Me.RushBoolColumn = new MyRushboolColumn
Me.Master_DataGridTextBoxColumn_1 = new Master_DatagridTextBoxColumn

...etc.

Just disppears! The entry that includes these columnstyles into my
tablestyle disappears with it. All that is left is the defining
classes, and the initial definitions:

Public RushBoolColumn as RushBoolColumn
Public Master_DataGridTextBoxColumn_1 as Master_DatagridTextBoxColumn

etc.

Naturally, I wind up with dozens of build errors, in a program that
was working perfectly before!

After painstakingly putting all of the missing code back in, the
program again runs fine. Until the next time it happens. Sometimes
this happens 2-3 times a day. Sometimes it doesn't happen at all. I
can't find a pattern, except that it seems to happen when I switch
between views and it seems to happen more often when I check the
datagrid properties window.

I am using Visual Basic 2002. I have never had these problems before,
though I have also never used a datagrid before. Can anyone help?

thank you,
Mike Cooper



Relevant Pages

  • Re: Objects and code from datagrid disappearing!
    ... > the code view, the instantiating code vanishes. ... All that is left is the defining ... > Public RushBoolColumn as RushBoolColumn ... > datagrid properties window. ...
    (microsoft.public.dotnet.general)
  • Re: Objects and code just disappearing!
    ... > the code view, the instantiating code vanishes. ... All that is left is the defining ... > Public RushBoolColumn as RushBoolColumn ... > datagrid properties window. ...
    (microsoft.public.dotnet.faqs)
  • Re: Objects and code just disappearing!
    ... > the code view, the instantiating code vanishes. ... All that is left is the defining ... > Public RushBoolColumn as RushBoolColumn ... > datagrid properties window. ...
    (microsoft.public.dotnet.faqs)
  • datagridtextboxcolumns and code disappearing!
    ... the code view, the instantiating code vanishes. ... All that is left is the defining ... Public RushBoolColumn as RushBoolColumn ... datagrid properties window. ...
    (microsoft.public.dotnet.languages.vb.controls)
  • Objects and code from datagrid disappearing!
    ... the code view, the instantiating code vanishes. ... All that is left is the defining ... Public RushBoolColumn as RushBoolColumn ... datagrid properties window. ...
    (microsoft.public.dotnet.general)