Dmitriy
Fri Sep 05 04:36:18 CDT 2003
> 3. i create a ordinary new datagrid with custom
> columnstyles.
What exactly these column styles customize? I am pretty sure the problem is
one of these column styles - I have had similar unpredictable exceptions
myself and they were definitely related to bugs in the custom column styles.
More on that - do you follow the correct order of table style/column style
creation given in MSDN?
> 4. assign datatable to datagrid.
How to you do that? I'd suggest sticking to the SetDataBinding method.
--
Dmitriy Lapshin [C# / .NET MVP]
X-Unity Test Studio
http://x-unity.miik.com.ua/teststudio.aspx
Bring the power of unit testing to VS .NET IDE
"Mats-Erik Grundh" <classe@Classeabc.se> wrote in message
news:1d8001c37390$6ad0cea0$a101280a@phx.gbl...
> The only row left in the stacktrace window is currentrow.
>
> There are no owner drawn/overide paint, keaybord or
> mousehandling in the form.
>
> 1. clickes an ordinary Button
> 2. in buttons click event i call a sub that catch data
> from server.
> 3. i create a ordinary new datagrid with custom
> columnstyles.
> 4. assign datatable to datagrid.
>
>
>
> >-----Original Message-----
> >No, it is not. I just hope you would be able to inspect
> this structure when
> >you double click the corresponding row in the Stack
> Trace. That's how the
> >debugger works - it can inspect variables only from
> current context, and
> >contexts are switched when you double-click in the Stack
> Trace window.
> >Unfortunately, I can't be 100% sure of this - I don't do
> such an advanced
> >debugging frequently.
> >
> >Anyway, I think the first things to be throughly checked
> are:
> >
> >- Custom painting
> >- Custom keyboard handling
> >- Custom mouse handling
> >
> >As you have said you experience this error even when you
> don't edit or
> >navigate the grid, custom painting would be the first
> candidate, I think.
> >
> >--
> >Dmitriy Lapshin [C# / .NET MVP]
> >X-Unity Test Studio
> >
http://x-unity.miik.com.ua/teststudio.aspx
> >Bring the power of unit testing to VS .NET IDE
> >
> >"Mats-Erik Grundh" <classe@Classeabc.se> wrote in message
> >news:1bc201c37374$983fbb60$a101280a@phx.gbl...
> >> Is the "msg" structure data saved in the
> >> nullreferenceexception exception?
> >>
> >> >-----Original Message-----
> >> >The stack trace eventually points to a Windows message
> >> handler. Do you
> >> >implement any custom Windows message handlers (say, by
> >> overriding WndProc or
> >> >PreProcessMessage methods)?
> >> >
> >> >If you will be able to see the "msg" structure
> contents,
> >> you'll find out the
> >> >exact message that causes the data grid to fail.
> >> >
> >> >--
> >> >Dmitriy Lapshin [C# / .NET MVP]
> >> >X-Unity Test Studio
> >> >
http://x-unity.miik.com.ua/teststudio.aspx
> >> >Bring the power of unit testing to VS .NET IDE
> >
> >.
> >