Reputation: 4292
I'm in a big trouble as in my project, suddenly designer.cs files are not loading and a Namespace related error is shown.
When I double click on a designer in solution explorer following error window appears.
I checked all the references are there in the reference section So I have no idea whats has happened. Its completely sudden! Highly appreciate your help in this regard...
Upvotes: 0
Views: 51
Reputation: 4292
I just removed the newly added class from the solution (a simple class with few properties) guessing some thing may be wrong with it as every thing started after adding that class. And now the solution is not giving any errors its compiling.
I wonder why adding a class may lead to such problems in the IDE!
Upvotes: 0
Reputation: 3563
This issue comes not because of any missing reference. The same error you can reproduce by creating a simple Windows Form
and add the Form1_Load
event in the code behind and delete. This issue will raise because the Designer.cs
file still have a reference to this event. Inorder to get back your UI, needs to delete the event handling line from cs
file.
Now let's come to your problem, go to the Designer.cs
file of your Window
and delete the below line of code.
this.dtpAdvanceDate.Format = System.Windows.Forms.DateTimePickerFormat.Short;
Upvotes: 2