FileVersionInfo.ProductName 속성
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
이 파일이 배포되는 제품의 이름을 가져옵니다.
public:
property System::String ^ ProductName { System::String ^ get(); };
public string ProductName { get; }
member this.ProductName : string
Public ReadOnly Property ProductName As String
속성 값
이 파일이 배포된 제품의 이름이거나 null 파일에 버전 정보가 포함되어 있지 않은 경우
예제
다음 예제에서는 메모장을 가져오기 GetVersionInfo 위해 호출 FileVersionInfo 합니다. 그런 다음 텍스트 상자에 인쇄합니다 ProductName . 이 코드는 인스턴스화되었다고 가정합니다 textBox1 .
private void GetProductName()
{
// Get the file version for the notepad.
FileVersionInfo myFileVersionInfo =
FileVersionInfo.GetVersionInfo(Environment.SystemDirectory + "\\Notepad.exe");
// Print the product name.
textBox1.Text = "Product name: " + myFileVersionInfo.ProductName;
}
Private Sub GetProductName()
' Get the file version for the notepad.
Dim myFileVersionInfo As FileVersionInfo = _
FileVersionInfo.GetVersionInfo(Environment.SystemDirectory + "\Notepad.exe")
' Print the product name.
textBox1.Text = "Product name: " & myFileVersionInfo.ProductName
End Sub