VSWebSite.AddFromTemplate Method (String, String, String, String, Boolean, String, String)
Creates a new ProjectItem in the Web site project.
Namespace: VsWebSite
Assembly: VsWebSite.Interop (in VsWebSite.Interop.dll)
Syntax
ProjectItem AddFromTemplate(
string bstrRelFolderUrl,
string bstrWizardName,
string bstrLanguage,
string bstrItemName,
bool bUseCodeSeparation,
string bstrMasterPage,
string bstrDocType
)
ProjectItem^ AddFromTemplate(
String^ bstrRelFolderUrl,
String^ bstrWizardName,
String^ bstrLanguage,
String^ bstrItemName,
bool bUseCodeSeparation,
String^ bstrMasterPage,
String^ bstrDocType
)
abstract AddFromTemplate :
bstrRelFolderUrl:string *
bstrWizardName:string *
bstrLanguage:string *
bstrItemName:string *
bUseCodeSeparation:bool *
bstrMasterPage:string *
bstrDocType:string -> ProjectItem
Function AddFromTemplate (
bstrRelFolderUrl As String,
bstrWizardName As String,
bstrLanguage As String,
bstrItemName As String,
bUseCodeSeparation As Boolean,
bstrMasterPage As String,
bstrDocType As String
) As ProjectItem
Parameters
bstrRelFolderUrl
Type: System.StringA relative URL for the folder in which to create the ProjectItem object. If this parameter is null or an empty string, the item is added to the root of the project.
bstrWizardName
Type: System.StringThe name of a template to use in creating the ProjectItem object.
bstrLanguage
Type: System.StringThe code language for the ProjectItem object; for example, "C#" or "VB."
bstrItemName
Type: System.StringThe name of the ProjectItem object as you want it to be within the project.
bUseCodeSeparation
Type: System.BooleanA Boolean value indicating whether to use the code-behind model. This parameter is used only when the project supports code-behind files; otherwise it is ignored.
bstrMasterPage
Type: System.StringThe relative path and name of the master page for projects that support master pages, and if applicable, the template; otherwise this parameter is ignored.
bstrDocType
Type: System.StringNot used.
Return Value
Type: EnvDTE.ProjectItem
A ProjectItem object.
See Also
EnvDTE
EnvDTE80
DTE2
VSWebSite Interface
VsWebSite Namespace
Referencing Automation Assemblies and the DTE2 Object
NIB: Finding and Sharing Project and Item Templates
Return to top