Properties afterproperties itemupdating
I should also point out that I know the difference between a metaphor and simile in case that was bothering you from the opening sentence.
I am nothing if not a masterful linguist after a beer or two or more.
I have a library that allows multiple folder content types. if you have changed the name of the column after creating the list, then try with the old name.
I am grouping the folders by content type but I don't want the group heading to say Content Type: whatever.
So I need to move the old values of these fields to different fields.
I am using an Item Updating event receiver (in 2010). After Properties, where the changed values are stored. Refer to this excellent blog post from Randy Williams for a complete overview of which property to use with each event : Working with Before Properties and After Properties on SPItem Event Receiver Side note #1: You should never open a new SPWeb inside a synchronous event receiver, as this is potentially a very costly operation.
The code seems pretty straightforward, but I can't get the the fields to update. Event Firing Enabled = True End Using End Sub You cannot update properties. That property contains the original values, and are for reference only (not saved back). Note that that property is a basic array of string (or more exactly a IEnumerable), not a SPList Item, although you access its values in a similar manner: , FIELD must be the Title (or Display Name) of the field. In your case, access instead the current web by using properties.
Even when hard-coding the values, the code runs successfully but the values aren't saved. Allow Unsafe Updates = True current Item("Prior Price") = 5.25 current Item. Web, and do not dispose of it (do not put inside a block). Allow Unsafe Updates unless you are specifically trying to update an item inside a GET request. Allow Unsafe Updates lightly as it exists to protect against vulnerabilities.
I tried Item Updated, which will update the values, but it's not going to work for my solution. Sample: Public Overrides Sub Item Updating(properties as SPItem Event Properties) My Base. It is not your case in the code you show, you should be able to directly edit properties.