Hi all
I have a website solution which contains a project with domain classes.
I have added a public auto property (get; set;) to one of the domain classes. A page on the website references this property - it was added to the page using IntelliSense.
The website project builds okay. But when I build the solution, I get the old 'Class does not contain a definition for Property' error. However, if I right click on the property in the aspx.cs file, it takes me right to the declaration in the domain class.
The other website project in the solution can call this property of the class without errors.
Actually using the website fails with the same exception.
Seems like Visual Studio is having some kind of weird episode here.
Any suggestions what might be going wrong?
Thanks
David
Edit: Here are some further observations in a series of steps.
- Clean Solution (says 14 succeeded; there are 16 projects in the solution)
- Build Solution (says 16 succeeded)
- Rebuild Solution (fails as described)
- Build Solution (fails as described)
At no point does the website actually work - it always gives the error.
It does appear to precompile successfully.
Edit 2: I have removed the project reference and re-added it, but the problem remains.
Edit 3: I have added a new webiste project to the solution and copied all the files across from the existing website to the new website. The problem exists in the new website as well as the existing one.