Tuesday 9 June 2009

Another surprise in SharePoint

I have a list with versioning enabled and a "Multiple line of text" field that can not be updated via the UI. The field is also configured to append text to the current text.

When updating the field and using SPItem.SystemUpdate(false) (in code) the field don´t get a new entry (as it does when editing a field of this type via the UI). Nope, it simply overwrites the current text and updates the field.

One solution to this is to concatenate the old value with the new, with the drawback that the datestamp will always stay the same until a new version of the item is created.
I removed the append option and did the appending of the field myself instead.

// Henrik

No comments: