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

I have a custom upload form that I want to incorporate with new document libraries. Ideally, user will be able to add document libraries with this updated link to their site on their own without having to use SPD.

What is the best way to modify the document library upload link? I'm open to development if that is needed.

share|improve this question
up vote 0 down vote accepted

For the upload and related links, there are 7 locations where links need to be modified:

1) Ribbon - Documents - New Document > Custom Action Hide

2) Ribbon - Documents - Upload Document > Custom Action Replace

3) Ribbon - Manage - View Properties > Custom List Definition (schem.xml) - Form

4) Ribbon - Manage - Edit Properties > Custom List Definition (schem.xml) - Form

5) ECB - View Properties > Custom List Definition (schem.xml) - Form

6) ECB - Edit Properties > Custom List Definition (schem.xml) - Form

7) "Add new item" >

  1. Custom List Definition (schem.xml) - View - XslLink
  2. XSL - Custom vwstyles.xsl

Steps 1 & 2:

<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="">
    <CustomAction Id="Ribbon.Library.Actions.ReplacementButton"
        Title="Replace a Ribbon Button">
            <!-- Hide OOTB Upload and New Document Buttons -->
            <CommandUIDefinition Location="Ribbon.Documents.New.AddDocument" />
            <CommandUIDefinition Location="Ribbon.Documents.New.NewDocument" />
            <!-- APC Upload Button -->
                <Button Id="Ribbon.Documents.New.AddDocument.ReplacementButton"
                    LabelText="Upload Document"
                    TemplateAlias="o1" />
                    CommandAction="javascript:alert('This button has been replaced.');" />

Steps 3 - 6

  <Form Type="DisplayForm" SetupPath="Layouts\MyView.aspx" Url="MyView.aspx" WebPartZoneID="Main" />
  <Form Type="EditForm" SetupPath="Layouts\MyEdit.aspx" Url="MyEdit.aspx" WebPartZoneID="Main" />

Steps 7

Essentially you'll be updating an XSL file.

Custom List Template > schema.xml > views.view.xsllink > custom_vwstyles.xsl

The blog post below walks you though all of the steps:


It looks like the upload page property is associated with the SPWeb not the SPList object per:

share|improve this answer
The step7 is not answered completely on that post... Can you provide another direction? Thanks Bruno – user13209 Nov 26 '12 at 15:41

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.