DataGridView crash when selecting Data Source

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have one Windows project that crashed on me when I tried to select the data
source on a DataGridView control after adding it to my project. Since then,
I can no longer set any data source fields on any controls anywhere in that
project. I can do it just fine in other projects on the same machine.

What can I do to fix this project, short of copying everything into a new one?
 
Well, I finally figured it out. This problem occurs when one of your
DataSources in your project is corrupt. Do the following to find out which
DataSource is corrupt and then recreate it...

- In both VB and C#, select your project in the Solution Explorer and
select Show All Files.
- In VB, Expand the My Project section, in C# Expand the Properties section
- Expand the DataSources section
- Right click on each of your project DataSources and select Exclude from
Project
- Try using a DataGridView or other controls that use the DataSource
options. They should work at this point.
- Slowly start including your DataSources again, testing after adding each
one individually. When the solution crashes, you know which one(s) are
corrupt. You can then recreate that DataSource as necessary.

<b>NOTE: Make sure you SAVE your project after selecing to include each
DataSource. If you don't, when the project crashes the IDE, you will have to
redo all of the steps you did prior = Not fun.</b>

I hope this helps others. Good luck!
 
Back
Top