Stupid ASP.NET designer: "could not be set on property" error message

by timvasil 11/5/2007 12:24:00 PM

I hardly ever use the designer, but when creating custom controls I like to do a cursory check in the design view to make sure nothing barfs too badly.

In the process of creating a menu control, everything worked great in the HTML view and at runtime, but in the designer I was puzzled to see this error:

The error is confusing since 'Menu' is a property of test:MenuControl.  Why would the designer be trying to set a property of the control to a reference to the control? 

Solution:  As it turns out, the problem stems from the fact that the control collection I was using as the 'Menu' property had a setter. That's it. As soon as I took out the setter, the designer was happy.

Stupid designer.

Currently rated 5.0 by 1 people

  • Currently 5/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags:

ASP.NET

Related posts

Comments

11/6/2009 4:38:42 AM

NinjaCross

FYK, here is a couple of hotfixes for that problem
code.msdn.microsoft.com/.../ProjectReleases.aspx
code.msdn.microsoft.com/.../ProjectReleases.aspx

NinjaCross it

Comments are closed

 

About the author

Tim Vasil Tim Vasil
I'm a software engineer living in Cambridge, MA.

E-mail me Send mail

Search

Calendar

<<  September 2010  >>
MoTuWeThFrSaSu
303112345
6789101112
13141516171819
20212223242526
27282930123
45678910

View posts in large calendar

Recent comments