I have a project that I've been working on for a while, where several
forms use DataGridViews to represent database information. The forms
are .NET 2.0, in Studio 2005. For the past couple of days, whenever I
click the little arrow in the top-right corner to show the
DataGridView Tasks subwindow, then click to expand the dropdown for
"Choose Data Source...", Studio crashes. If I "Debug" the app, of
course I don't have any symbol tables, so I can't do much, but I do
see that it's because of an unhandled null pointer exception. I can
only assume this is being generated because Studio is trying to
enumerate all the available project data sources, and coming up with a
null pointer somewhere. Also, if I just select the item, then go to
"DataSource" under Properties, and try to expand that combo box, I get
an error "Object reference not set to an instance of an object" -- the
boilerplate null pointer exception. In that case, Studio does *not*
crash. Obviously, it's still a big impediment.
This happens on existing, older forms, which I designed months ago,
when the Data Source enumerator was obviously not broken. Using the
Data --Show Data Sources menu option works fine -- it lists all the
DataSets that I've defined.
I'm really at a loss how to proceed -- the project is managed by
SourceSafe, so I could roll back to previous versions, but it's been
under heavy development, and I don't know what versions of Form A
correspond to what version of Form B, nor which versions of Forms A
and B correspond to which version of the project file. It worked a
month or two ago, the last time I tried to add a DataGridView, and it
didn't work starting at least a week ago -- that's all the information
I have to go on. If I could fix the problem *without* rolling back,
I'd be happiest... maybe there's some kind of cache I can clear or
something? I'm really not familiar enough with the underpinnings of
devenv to fix it all alone.