Welcome to MSDN Blogs Sign in | Join | Help

Chris Johnson

All about Chris Johnson, SharePoint Products & Technologies & Other Stuff.
Deploying files under the \TEMPLATES directory in a SharePoint VSeWSS project

A common thing you might want to include in a SharePoint solution is to include various files that are deployed to the \Template directory.  These might be images (\Template\Images) or Aspx pages that you would like put in a folder in the Layouts directory.

Typically to do this you would include in your WSP Solution manifest file a <TemplateFile>  node that deploys your file there. 

The VSeWSS toolkit makes building Solutions easy & helps with deploying your Template files in a pretty nifty way.

To deploy a file to any location under the \Template directory do the following:

Add a new project item to your VSeWSS project and pick the Template item.

image

You will end up with your file under a folder called Templates

image 

This will end up deploying your file to the root of the \Template directory.  To change where it is deployed to simply create the folder structure you wish below the Template folder in your project and drag your file into the appropriate folder.

E.g.

image

This will result in your ASPX file being deployed to the \Template\LAYOUTS\MyProject\ directory.  It builds the manifest xml for you like so:

image

This will allow you to deploy the majority of your projects supporting assets.

If anyone has comments or suggestions on VSeWSS please comment below.  We are listening!!!

-Chris.

Posted: Friday, January 11, 2008 1:51 PM by chjohn

Comments

Joel said:

I installed the VSeWSSCTP 1.1 and I'm working on a layouts ASP.Net app.  When I import an existing aspx page, none of the asp.net magic seems to be tying the designer-dropped code to the partial code-behind file.  Am I missing something?  Thanks for your help!  Great work on the VSeWSS.  Feel free to drop me a line at jcade (at) microlinkllc.com.

Thanks!

# January 24, 2008 3:48 PM

chjohn said:

Hi Joel,

The behaviour you seeing is how it currently works.  

We are looking at how this can be made better so that ASP.Net magic works better in these cases.  However, this would be in a future release.

Thanks,

Chris.

# January 24, 2008 4:19 PM

Mirrored Blogs said:

Body: Over the past few weeks our team has been working on creating a user guide and sample code for

# February 11, 2008 1:50 PM
Leave a Comment

(required) 

(required) 

(optional)

(required) 

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Page view tracker