Sync button for Document Library created with custom list definition

In my previous post I documented the limitation of SP2013 and SkyDrivePro related to document libraries that are created using custom list definition. I found one workaround for this.

In your list template element specify the Type=101 (DocumentLib) and DocumentTemplate=10000. You must also specify the FeatureId attribute. Id of the Feature that deploys the List template element.xml


Adjust your list instance also with TemplateType=101 and include the FeatureId Attribute.


There you go, now we have the SYNC button.


Note that if your Event Receiver is targeted to the custom list template id (eg ListTemplateId=10000), it won’t fire. So you should change the target to the specific list instance by using ListUrl attribute.


This entry was posted in SharePoint 2013, Uncategorized and tagged . Bookmark the permalink.

15 Responses to Sync button for Document Library created with custom list definition

  1. Hi Anand,

    Nice finding and post!
    I have one question. How about if you have more than one custom list definitions? What happens if i specify Type=101 for both of the custom list definitions?


  2. Hi Anand,
    Thanks for the reply.
    I tried this scenario actually as I had this requirement in my current project.
    The thing is Type should be unique within the feature. So if you have two list definitions with same type within the same feature it wouldn’t work. So i had to put the definitions in different features to make by two custom list definitions work.


  3. John Knowles says:

    This is wonderful. The only problem is, I’m a rookie, and not exactly sure how to access my list template element, nor do I know what that means. When I go to Site Settings, there is a List Templates option, and it takes me to a List Template Gallery that has no files in it. Can you assist or provide more details?

    • Hi John,

      This article talks about a custom list Definition that is created using Visual Studio. The element.xml you would find it as part of the SharePoint solution.

      Would you mind tell me how you have created you custom list defintion?


      • John Knowles says:

        Oh…I have not used Visual Studio. The Sync button does not appear on my primary document library and thought I could use your solution to fix that. To my knowledge I have not created a custom list definition.

      • Hi John,

        You can enable SYNC button on document lib (that are not created using custom list Definition) in the document lib Settings

        Library Settings -> Advance Settings -> Offline Client Availability-> Allow items from this document library to be downloaded to offline clients?
        Select “Yes”.

        Then you should see the SYNC button.


  4. John Knowles says:

    Hi. Thank you for this post. I am having the problem too. Since I am a rookie at SharePoint, I am not sure how to access the list template element. When I got to Site Settings, I see an option for it, but when I click it there are no files there. Can you provide some more details for someone who is so new to this?

  5. THanks for posting. but what happens if i already have list with different template id’s. They will not work or?

    Kind regards,

    Paul Keijzers

  6. derekgusoff says:

    Really nice find, and thanks for sharing it. You really helped me out with this one. And Sanjay is correct, if you have multiple libraries you can put them in separate features.

  7. Jackob says:

    Hi Anand.

    Thank you for your post.
    I tried it and experienced following issue.

    – I created a doc lib list definition as explained in your post.
    – in the schema.xml of this doc lib, I reference my custom content type.
    – I deployed the entire solution and all works fine.
    – then I manually added a managed metadata field to my content type (through the SharePoint UI).
    – after that, the synchronisation doesn’t work anymore!

    It seems that the problem is caused by the hidden TaxCatchAll column that SharePoint adds to the doc lib. If I remove it (through PowerShell) from the doc lib, the synchronisation works fine again.

    If I create an OOTB SharePoint doc lib, manually add my custon content type on it, the synchronisation works fine even if the content type contains a managed metadata field!

    Do you have any idea, what can cause this problem or how I can solve it?

    Thank you very much.

    Best regards.


    • Hi Jackob,

      Sorry for the delay. I haven’t had a chance to try this option with tax field. I will let you know if found something.

      Best Regards

      • Jackob says:

        Hi Anand.

        Thank you for your answer.

        We are making more tests and it seems that the synchronization works again even with managed metadata fields if you add the “folder” content type on the document library.
        We had removed it from our schema.xml of the list definition for the document library.

        I will let you know once we have found a solution.


  8. Jackob says:

    Hi Anand,
    a few days ago I posted a question on your blog.
    Did you get it?
    Because I cannot see it on your blog.
    Thank you very much for your blog and your help.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s