Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I got a simple cusom list with some columns created in Visual Studio. these columns are from a contenttype (also created in visual studio too). It was asigned to it and works very well.

I deployed, my sharepoint provider hosted app, it to my sharepoint online system. It works very well.

Now I added a new column to the contenttype. Deployed it and it won't display on the list. But the list was recreated.

So I recreated the list in my visual studio. I thought this sooled my problem. But it doesn't the new column doesn't appear in the list.

So my questions:

  1. Is that way of deploying a new column the right way?
  2. Is it always needed to recreated the list is one column wil be added?
  3. Does there exist an automated upgrade function like Entytyframworks "Hey theres a ne schmea so i migrate it"? :)

Thx a lot.

share|improve this question

1 Answer 1

up vote 2 down vote accepted

How are you adding columns in Content Type? Declarative.. meaning XML?

If yes, than you will either have to write Feature Upgrade Actions; specially check the <AddContentTypeField> where PushDown attribute decides whether to push the new field in the lists/libraries where the content type is being used or not..

OR

We (personally) have a custom Feature Event Receiver which adds the new fields programmatically and update the existing lists/libraries that are using the Content Type.

However, deleting the list and recreating should give you the new columns.. But it's not feasible all the time, specially when users are already using the list..

share|improve this answer
    
Hi thx for your reply. Yes i do it declarative. So i must use feature upgrade actions. At the moments it's not productive but i was worried about the upgrade for future versions. Thx for your hint with the upgrade actions :) –  Sascha May 11 at 11:29

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.