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

Scenario : The 14 hive template/layouts folder has an ASPX page that is shown to users. I want to show some more information within that page.

I am able to open that ASPX page. It has AutoEventWireup="False" and there is no c# based code within the ASPX page.

I do not want to modify this ASPX page as it is an Out-of-box file.

I would like to know what is the best approach to show "some more information such as customer name, address" on this page.

I don't know how can I reference or add my custom webpart in this page. Also I do not get to see "Edit page" option when this page is loaded.

PLease suggest.

share|improve this question
which out of the box page do you want to modify? web parts cannot be added to application pages stored in the _layouts directory. – Robert Aug 15 '11 at 21:13
Is it correct that you want to "inject" web part without modifying .aspx file? – AlexSSE Aug 16 '11 at 7:43
AlexSSE -> Yes I don't want to modify the OOB aspx page. – Anirudh Aug 16 '11 at 15:13

You will need to make a copy of this page and edit that on the filesystem. As you say, it is a bad idea to modify an OOB page as it will probably get overwritten when you upgrade to the next version or apply a service pack. You may also lose functionality in future versions.

Ideally, you should deploy your application page using a feature, so that you can do it again without making manual changes. If for some reason you really must modify the OOB page, at least you will be able to easily re-deploy it if it gets changed (add code to your feature receiver to put the old file back if you retract the feature to get your farm back into a supported state - or better still, don't modify the OOB pages!).

Certain application pages can be re-mapped using the SPWebApplication.UpdateMappedPage method, allowing you to redirect from the OOB application page to your custom page. See this blog post (I haven't tested this). Unfortunately this only covers login, logout, and a few error pages and confirmation. If you need to modify other OOB pages you will need to deploy/retract as described above. Again, try to avoid it if you can.

share|improve this answer
If I make copy of the OOB aspx page and create my own custom page and then deploy using feature, how can I tell the sharepoint server to start loading my custom ASPX page? Take for example Signout.aspx, this page gets called when someone clicks on signout. Suppose if you create custom page from this, how can you tell sharepoint to look at mysignout.aspx and not signout.aspx? – Anirudh Aug 16 '11 at 15:16
In general you will need to use a feature to replace and retract as described above. As luck would have it there is a method in the SharePoint Administration namespace that can replace certain pages, including the Signout.aspx page. I have added a link in the answer above. – SPDoctor Aug 16 '11 at 16:15
  1. Create a web-part-page
  2. Make sure you pick the layout that works for number of web part you are going to insert.
  3. Add web parts to this page
share|improve this answer
I mentioned in my original post that it is an Out-of-box page. So I can't create web part page. – Anirudh Aug 15 '11 at 20:27

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.