FileVersionInfo.Comments Eigenschaft

Definition

Ruft die Kommentare ab, die der Datei zugeordnet sind.

public:
 property System::String ^ Comments { System::String ^ get(); };
public string Comments { get; }
member this.Comments : string
Public ReadOnly Property Comments As String

Eigenschaftswert

Die kommentare, die der Datei zugeordnet sind oder null wenn die Datei keine Versionsinformationen enthält.

Beispiele

Im folgenden Beispiel wird aufgerufen GetVersionInfo , um das FileVersionInfo Editor-Steuerelement abzurufen. Anschließend werden die Kommentare in einem Textfeld gedruckt. Dieser Code setzt voraus, dass textBox1 instanziiert wurde.

void GetComments()
{
    // Get the file version for the notepad.
    FileVersionInfo myFileVersionInfo =
        FileVersionInfo.GetVersionInfo(Environment.SystemDirectory + "\\Notepad.exe");
    // Print the comments in a text box.
    textBox1.Text = "Comments: " + myFileVersionInfo.Comments;
}
Sub GetComments()
    ' Get the file version for the notepad.
    Dim myFileVersionInfo As FileVersionInfo = _
       FileVersionInfo.GetVersionInfo(Environment.SystemDirectory + "\Notepad.exe")

    ' Print the comments in a text box.
    textBox1.Text = "Comments: " & myFileVersionInfo.Comments
End Sub

Hinweise

Diese Eigenschaft enthält zusätzliche Informationen, die zu Diagnosezwecken angezeigt werden können.

Gilt für: