Export (0) Print
Expand All

_Solution.TemplatePath Property

Gets the full path and name of the directory that contains templates for the specified type of project.

Namespace: EnvDTE
Assembly: EnvDTE (in envdte.dll)

string TemplatePath [
	[InAttribute] string ProjectType
] { get; }
/** @property */
String get_TemplatePath (/** @attribute InAttribute() */ String ProjectType)

JScript supports the use of indexed properties, but not the declaration of new ones.

Parameters

Property Value

The full path and name of the directory that contains templates for the specified type of project.

For example, TemplatePath(vsVBProjectKind) returns the path <Visual Studio root installation directory>\VBProjects.

TemplatePath is similar to ProjectItemsTemplatePath except that it is for projects rather than templates.

Sub TemplatePathExample()
   ' Open a Visual Basic solution before running this example.
   Dim soln As Solution

   ' Create a reference to the solution.
   soln = DTE.Solution

   ' List the path to the templates for the project type.
   MsgBox(soln.TemplatePath(DTE.Solution.Item(1).Kind))
End Sub

Community Additions

ADD
Show:
© 2014 Microsoft