RishadanPort
asked on
C# Code Property Error
Hello Experts. When I am compiling my code, or at random times when I am designing a user control that contains the property 'ManuallyAddedCurves', it gives me the same error. I even comment out the code (which I really don't use), and it still gives me the same error. I am not sure how to fix this... The error is really bugging me, however my code still works fine.
-------------------------- -
Microsoft Visual Studio
-------------------------- -
Code generation for property 'ManuallyAddedCurves' failed. Error was: 'Type 'ModelEditorApplication.Co mmon.Manua llyAddCurv eNameEvent Args' in Assembly 'ModelEditor, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' is not marked as serializable.'
-------------------------- -
OK
-------------------------- -
--------------------------
Microsoft Visual Studio
--------------------------
Code generation for property 'ManuallyAddedCurves' failed. Error was: 'Type 'ModelEditorApplication.Co
--------------------------
OK
--------------------------
ASKER
And if I close Microsoft visual studio, and then reopen it... the Error messages are no longer sent to me.... for a while.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
I don't use more then 1 machine for this project. It only happens periodically, and once I close Visual Studio, and reopen it, the error disappears. What could cause this? (The error then later, at some random time popups up again, but I can still compile and run fine)
I don't know what would cause this, but you didn't indicate .NET version and operating system.
ASKER
Microsoft Visual Studio 2005
Version 8.0.50727.762 (SP.050727-7600)
Microsoft .NET Framework
Version 2.0.50727 SP1
Version 8.0.50727.762 (SP.050727-7600)
Microsoft .NET Framework
Version 2.0.50727 SP1
ASKER
Operating system Windows XP
Operating system?
Is the 'ManuallyAddCurveNameEvent Args' marked with an Editor attribute and 'ModelEditor'?
ASKER
I don't think I put any attributes.
ASKER
Nothing except the Main Method has any attributes.
Main is just simply declared like this:
[STAThread]
static void Main()
Main is just simply declared like this:
[STAThread]
static void Main()
When does this occur? Can you attach a .png screenshot of the circumstances?
ASKER
Currently the situation stopped happening after I closed Visual Studio, and then reopened it. It previously happened every time I tried compiling. It would issue this error popup box 5 times repeatedly (after clicking the OK button each time).
It would also show the error when I was working with the UserControl that had the property 'ManuallyAddedCurves'. (again it would popup the error box 5 times after clicking ok each time). If I see it again I will post a screen shot
It would also show the error when I was working with the UserControl that had the property 'ManuallyAddedCurves'. (again it would popup the error box 5 times after clicking ok each time). If I see it again I will post a screen shot
ASKER
I had previously tried closing and reopening Visual Studio... but again the situation started happening a day or more later, so still think the problem lurks out there.
ASKER
After restarting Visual Studio a while ago, the problem has not occured since then... however I am still puzzled by the problem
ASKER