Condividi tramite


Proprietà _Solution.TemplatePath

Ottiene il percorso completo e il nome della directory contenente i modelli per il tipo di progetto specificato.

Spazio dei nomi:  EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)

Sintassi

'Dichiarazione
ReadOnly Property TemplatePath ( _
    ProjectType As String _
) As String
string this[
    string ProjectType
] { get; }
property String^ TemplatePath[[InAttribute] String^ ProjectType] {
    String^ get ([InAttribute] String^ ProjectType);
}
abstract TemplatePath : 
        ProjectType:string -> string with get
JScript non supporta le proprietà indicizzate.

Parametri

  • ProjectType
    Tipo: String

    Obbligatorio. Un GUID che identifica il tipo di progetto, da PrjKind.

Valore proprietà

Tipo: String
Percorso completo e nome della directory contenente i modelli per il tipo specificato di progetto.

Note

TemplatePath(vsVBProjectKind) restituisce, ad esempio, il percorso <Visual Studio root installation directory>\VBProjects.

TemplatePath è simile al metodo ProjectItemsTemplatePath, con la differenza che è applicabile ai progetti anziché ai modelli.

Esempi

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

Sicurezza di .NET Framework

Vedere anche

Riferimenti

_Solution Interfaccia

Spazio dei nomi EnvDTE