I'm trying to tweak a project template file exported by Visual Studio's "Export Template" wizard. At first glance this looks like just a garden-variety zip file, but it's not:
The Compressed (zipped) Folder is invalid or corrupted.
Is this something specific to my setup, or is there something non-standard about the zip format used by Visual Studio templates?
Edit I tried again and actually #2 above isn't true - I can un-zip, edit, and re-zip and VS sees the template. Still stumped as to why I couldn't manipulate the original archive directly, but I'm moving on.
Visual Studio templates Item templates, such as code files, XML files, HTML pages, and Style Sheets, appear in the Add New Item window. These templates provide a starting point for users to begin creating projects, or to expand existing projects.
The default location is %USERPROFILE%\Documents\Visual Studio <version>\My Exported Templates. If you did not select the option Automatically import the template into Visual Studio in the Export Template Wizard, locate the exported template. Then, copy it to the user item template directory.
By default, templates installed with Visual Studio are located in: %ProgramFiles(x86)%\Microsoft Visual Studio\2019\<edition>\Common7\IDE\ProjectTemplates\<Language>\<Locale ID> %ProgramFiles(x86)%\Microsoft Visual Studio\2019\<edition>\Common7\IDE\ItemTemplates\<Language>\<Locale ID>
Go to Documents\Visual Studio Version\Templates\ProjectTemplates and create a new folder to separate your template from the default templates of visual studio. You will see the newly created template as shown below. Give the name of the project and click on 'Ok' button.
Solution is here to find: Exported Project Template from VS2008 but it is corrupted? In short: don't zip the directory, go into the directory, select all files and zip them into an archive.
Visual Studio templates use the standard ZIP`ing format. I've succesfully compressed and uncompressed these files many times in the past.
What ZIP tool are you using?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With