server error

server error

Old forum URL: forums.lhotka.net/forums/t/10066.aspx


DanielK posted on Sunday, February 13, 2011


Hey guys i'm facing a problem on my published and uploaded application to the server. when i try to insert and update it populates the following error message. "Object is not valid and can not be saved" any one can help me?

JonnyBee replied on Sunday, February 13, 2011

This is caused by your object having broken rules (with severity Error) and thus is Invalid.

Csla will throw this exception if you try to call Save on an object that is invalid.

So check the broken rules collection and your rules for possible problems.

 

DanielK replied on Sunday, February 13, 2011

Thanks Jonny, But how could i check The BrokenRulesCollection?

thanks

Daniel

DanielK replied on Sunday, February 13, 2011

Hey guys, let me elaborate what i did which causes this error. I changed one of the column length of my table from 50 to 100. and updated all my insert and update procedures accordingly. Do u thing i have to change anything from my classes side?

thanks

Daniel

DanielK replied on Sunday, February 13, 2011

oh, thanks for the idea i got it. it was in validation section. I will never forget the BrokenRulesCollection any more...loool

thanks a lot

Daniel

Marjon1 replied on Sunday, February 13, 2011

That suggests that there is a broken rule on the object (or one of it's children) that is preventing the call the save working, check the BrokenRulesCollection on the object for a bit more information. Does your save button have any logic to prevent saving if the object isn't valid?

Copyright (c) Marimer LLC