Upgrading a SharePoint list instance that was deployed via feature
I'm curious how others address this issue. Using VSEWSS 1.3, I have created a site content type, a list definition (w event receivers), and a list instance. All of them are in the same WSP solution and each is activated individually via features.
Now let's 开发者_StackOverflowassume that all the features have been activated for some time, and the list instance contains a number of items (that can't be deleted). Now suppose I need to make a change to the schema.xml (inject some javascript, modify views, whatever) of the list.
Is it even possible to "upgrade" the schema of the existing list instance? Otherwise I would think I'm stuck creating a new instance and copying items over.
In my experience, the schema of the list instance will be upgraded most of the time. But if you have made manual customizations to the content type instance or to the list instance's fields, that can break inheritance to the site content type and the list definition resulting in the schema changes not being passed to the list instance. However, even in this latter case, changes to the event receiver will still be picked up by the list instance.
精彩评论