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 created some custom lists (with content) on a site I'm using for prototyping. I want to make a feature (via Visual Studio) that automatically adds these lists (plus content) to any site the feature is activated on. I need to move the lists on my prototype site to my Visual Studio project as list instances. What is the best way to go about doing this?

Currently the approach I'm trying is to save the whole prototype site as a site template (.wsp file), then creating a new project in Visual Studio using the "Import SharePoint Solution Package" template, selecting only the lists I want. Then I copy the stuff in the new project into my original project. However, this doesn't seem like the proper way to do things.

share|improve this question
add comment

1 Answer 1

up vote 2 down vote accepted

Normally, when you have a list to be created and deployed to SharePoint using Visual Studio, you end up in creating a List definition along with a custom content type as a feature. There are several blogs and posts regarding the same in the internet. Its pretty simple.

But I believe in your case, you have multiple lists to be deployed as a single solution. There is a similar query in SPSE with details to how you do it.

share|improve this answer
add comment

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.