Visual Studio Development Bookmark and Share   
 index > Visual Studio Extensibility > VSX Project Template with Hidden LocationField
 

VSX Project Template with Hidden LocationField

I currently have a need with a vs2008 project template to hide the location field for new project and use the IWizard to determine the correct location for the project. While the wizard works as I want it to, the problem lies with the hiding/disabling the location field. When you click the “Ok” button on the new project dialog with the location field hidden or disabled the dialog will exit and say not a valid URI. This happens before getting to the wizard so I am not sure want step to take to fix this issue. I have looked for other samples of this but haven’t found a solution so any help would be great.

 

Thanks in advance

ShawnC.

 

< VSTemplate Version = "3.0.0 " Type = "Project " xmlns = "http://schemas.microsoft.com/developer/vstemplate/2005 ">

  < TemplateData >

    < Name > DSL Domain</ Name >

    < Description > A project for creating a DSL Domain</ Description >

    < Icon > DSLDomain.ico</ Icon >

    < SortOrder > 30</ SortOrder >

    < NumberOfParentCategoriesToRollUp > 1</ NumberOfParentCategoriesToRollUp >

    < DefaultName > DSLDomain</ DefaultName >

    < ProvideDefaultName > false</ ProvideDefaultName >

    < CreateNewFolder > false</ CreateNewFolder >

    < LocationField > Hidden</ LocationField >

    < EnableLocationBrowseButton > false</ EnableLocationBrowseButton >

    < PromptForSaveOnCreation > false</ PromptForSaveOnCreation >

    < BuildOnLoad ></ BuildOnLoad >

  </ TemplateData >

  < TemplateContent >

    < Project File = "DSLDomain.csproj " ReplaceParameters = "true ">

     

    </ Project >

  </ TemplateContent >

  < WizardExtension >

    < Assembly > DSLWizard, ...</ Assembly >

    < FullClassName > DSLWizard.ProjectWizard</ FullClassName >

  </ WizardExtension >

</ VSTemplate >

 

ShawnC  Thursday, October 15, 2009 7:38 PM
Hi, ShawnC
TheVS will check the location value of the project before you create the project by wizard, for it is the only chance for the visual studio to set the locaiton of the newly created project. SoNULL is forbidden here.
Maybe you have to move the newly created project to the loaction you wanted by the File,Copy method in you implementation of the RunFinished() method.
Thanks
Chao
Chao Kuo  4 hours 11 minutes ago

You can use google to search for other answers

Custom Search

More Threads

• When running (debugging) my DSL language, the properties window is empty after a while ??
• object alignment in debug application
• [How to]add a Keyboard Shortcut to my custome menu/button
• CreateDocumentWindow example
• code completion/Intellisense problem
• VsPackage Loaded only for VSDB
• Reference error
• SDK Package: Show modal dialog in Visual Studio Environment
• Interesting problem with SolutionContext.ConfigurationName
• SDK 1.1 Getting Started page