Error creating solution. The maximum total file size limit (10485760 bytes) has been exceeded in SharePoint 2010.

I ran into this error when I was creating new upgraded solutions from 2007 templates and needed to get around it. Normally I would have used “stsadm -o setproperty -propertyname max-template-document-size -propertyvalue 50000000” to do so but sadly I kept getting a “Windows SharePoint Services Tool Has Stopped Working” error so I needed to find another way. Then I thought of using PowerShell to do the same thing, so I created a script to do so. I noticed that someone had created some script for enabling the Developer Dashboard. Since the property “MaxDocumentTemplateSize” is a part of the same SPWebService class, I decided to retrofit it to meet my needs. I hope it helps you.

This script will by default reset the size of your WSP solution creation size to 50mb. If you would rather something different then call the script with the parameter “TemplateDocSize” and set it to your choice in bytes.

To Download the PowerShell Script Click Here

Use:

UpdateMyDocTemplateSize –MaxDocumentTemplateSize <Number Of Bytes>

Example:

UpdateMyDocTemplateSize (Reset Size to 50mb)

UpdateMyDocTemplateSize 30000000 (Reset size to 30mb)

UpdateMyDocTemplatesize –MaxDocumentTemplateSize  30000000 (Reset size to 30mb)

About these ads
This entry was posted in Uncategorized. Bookmark the permalink.

One Response to Error creating solution. The maximum total file size limit (10485760 bytes) has been exceeded in SharePoint 2010.

  1. GFF says:

    路過看看哦,請加油—-幫忙踩個人氣 http://wth.tw

Leave a Reply

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

WordPress.com Logo

You are commenting using your WordPress.com 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 )

Google+ photo

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

Connecting to %s