May 25, 2008

Vs.Net IDE Designer view Error : Object of Type "Xcannot be converted to type "X""




If this error occurs the Designer won't be able to show the controls of the form but will be able to show them at runtime, to eradicate this problem, close the designer view from the IDE, delete the .resx file associated with the .cs file of the form, then clean and rebuild the project.

The designer view will now be able to be loaded in the IDE.
Sometimes, even after the designer loads the UI, the resx file is missing, to correct this, just change any value of any control in the designer view and then change it back to the original value (like the text of a label)