如何调用向导来添加新的项目模板

How call a wizard to add new Item Template

我有一个通过向导生成的项目模板。 现在我想通过同一个向导添加一个新的项目模板。 添加新项目模板时如何调用向导。

示例:

[添加到项目模板]

[Wizard/Form]

[添加新的物品模板]

[显示向导模板]

[显示新的Item/class]

项目模板代码:

<VSTemplate Version="3.0.0" xmlns="http://schemas.microsoft.com/developer/vstemplate/2005" Type="Item">
  <TemplateData>
    <DefaultName>class1.cs</DefaultName>
    <Name>Myproject class1</Name>
    <Description>Myproject Class</Description>
    <ProjectType>CSharp</ProjectType>
    <SortOrder>10</SortOrder>
    <Icon>Myprojectclass1.png</Icon>
  </TemplateData>
  <TemplateContent>
    <References>
      <Reference>
        <Assembly>System</Assembly>
      </Reference>
      <Reference>
        <Assembly>System.Linq</Assembly>
      </Reference>
      <Reference>
        <Assembly>System.Threading.Tasks</Assembly>
      </Reference>
    </References>
    <ProjectItem SubType="Code" TargetFileName="$fileinputname$.cs" ReplaceParameters="true">class1.cs</ProjectItem>
    <CustomParameters>  
        <CustomParameter Name="$username$" Value="$safeitemrootname$"/> 
        <CustomParameter Name="$rootnamespace$" Value="$safeitemrootname$"/>
        <CustomParameter Name="$registeredorganization$" Value="$safeitemrootname$"/>
    </CustomParameters>  
  </TemplateContent>
    <WizardExtension>
    <Assembly>MyProjectWizard, Version=1.0.0.0, Culture=Neutral, PublicKeyToken=f7a1fcb8d457e160</Assembly>
    <FullClassName>MyProjectWizard.WizardImplementation</FullClassName>
  </WizardExtension>
</VSTemplate>

我已经找到了解决方法,没有其他方法可以不调用模板项key.snk。

因为当我调用项目模板时,我必须实施我选择的项目创建的项目,唯一的方法是 key.snk。

如果他们有不同的形式请回答这个问题,我想知道是否有更多的方式来调用Item模板。