Condividi tramite


Proprietà Document.FullName

Ottiene il percorso completo e il nome del file dell'oggetto.

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

Sintassi

'Dichiarazione
ReadOnly Property FullName As String
string FullName { get; }
property String^ FullName {
    String^ get ();
}
abstract FullName : string with get
function get FullName () : String

Valore proprietà

Tipo: String
Una stringa che rappresenta il percorso completo e il nome del file dell'oggetto.

Note

La proprietà FullName è nota come proprietà FileName in alcune versioni di Visual Studio.

Esempi

Sub FullNameExample(ByVal dte As DTE2)

    dte.ItemOperations.NewFile()

    Dim doc As Document = dte.ActiveDocument

    ' Display the new document's temporary location.
    MsgBox(doc.ActiveWindow.Caption & " is stored at " & doc.FullName)

End Sub
public void FullNameExample(DTE2 dte)
{
    dte.ItemOperations.NewFile(@"General\Text File", "", 
        Constants.vsViewKindPrimary);

    Document doc = dte.ActiveDocument;

    // Display the new document's temporary location.
    MessageBox.Show(doc.ActiveWindow.Caption + " is stored at " + 
        doc.FullName);
}

Sicurezza di .NET Framework

Vedere anche

Riferimenti

Document Interfaccia

Spazio dei nomi EnvDTE