SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there any chance to achieve this? The sharepoint project and the silverlight web part, which is called by the aspx, are linked by this template. I played with module and feature xml files but i couldn't manage to deploy the aspx to subsite.

unedited version of elements.xml of the module:

<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="">
  <Module Name="SitePages">
    <File Path="SitePages\VisitorTracking.WebPartWebPartPage.aspx" Url="SitePages/VisitorTracking.WebPartWebPartPage.aspx" Type="GhostableInLibrary"/>
share|improve this question
Have you added the aspx file to your module, aswell as add that module to a feature? That's what I did to get my site template working. Might be stupid questions but I just wanted to make sure that I understand what you've done so far. – K.W Feb 9 '12 at 9:41
I have added both of them. It deploys the aspx to site collection site pages library with the default elements.xml above. – onatm Feb 9 '12 at 9:45
up vote 1 down vote accepted

Where are you storing this aspx file ? Mostly, aspx files are stored in the layouts folder, although they can also be stored in pages (or any other) libraries.

If you want it to go into _layouts folder, nothing has to be done for subsites.

If you want it to be stored in a library on subsite level, please provide the elements.xml file from your module. This way we can check what might be going wrong.

This is what my module looks like:

 <Module Name="MasterPage" Url="_catalogs/masterpage" RootWebOnly="TRUE">
    <File Path="MasterPage\" Url="" Type="GhostableInLibrary">
      <Property Name="ContentType" Value="$Resources:cmscore,contenttype_masterpage_name;" />
      <Property Name="UIVersion" Value="4" />

So the Url property of the Module will be the List to where u need to provision. The Path property of the File is the location in your solution. The Url property of the file is the location to store it. (in my example it will be in the root of masterpage libary, if you want it to be in a subfolder u can use: Url="subFolder/..." for the File Url property)

So for sitepages this Module Url should be "SitePages":


share|improve this answer
i edited the question to reply yours. – onatm Feb 9 '12 at 8:43
I updated my answer, You need to specify the Url in ur Module as mentioned on – Frederik P. Feb 9 '12 at 15:12

Your Answer


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.