Sharepoint event receiver itemupdating beforeproperties
If the name isn’t changed, the changes are saved to the Share Point list.
To prevent users from changing the name of the planet, you can develop a Item Updating event receiver.
The changed values can be retrieved from the After Properties of the incoming properties argument.
You could think that the current values are stored in the Before Properties of the item but that’s not true: the Before Properties are unreliable at this point. When the name of the planet is changed, the update is canceled and an error message is returned to the user.
So I'm trying to accomplish this kind of functionality on my Share Point 2010 list: I have a field of type choice in my list, which has 7 values and i want users not to be able to change the value of that field from values 2,3,4,5,6,7 to value 1.
I've written an event receiver for that list, here's my code: Use Item Updating event and then afterproperties contains changed value and List Item contains original value of a field.