FileVersionInfo.ProductBuildPart プロパティ

定義

このファイルに関連付けられている製品のビルド番号を取得します。

public:
 property int ProductBuildPart { int get(); };
public int ProductBuildPart { get; }
member this.ProductBuildPart : int
Public ReadOnly Property ProductBuildPart As Integer

プロパティ値

このファイルに関連付けられている製品のビルド番号を表す値。ファイルにバージョン情報が含まれていない場合は null

次の例では、 を呼び出 GetVersionInfo してメモ帳の を FileVersionInfo 取得します。 次に、 を ProductBuildPart テキスト ボックスに出力します。 このコードは、 textBox1 がインスタンス化されていることを前提としています。

private:
    void GetProductBuildPart()
    {
        // Get the file version for the notepad.
        FileVersionInfo^ myFileVersionInfo =
            FileVersionInfo::GetVersionInfo( Environment::SystemDirectory + "\\Notepad.exe" );

        // Print the product build part number.
        textBox1->Text = String::Concat( "Product build part number: ", myFileVersionInfo->ProductBuildPart );
    }
private void GetProductBuildPart()
{
    // Get the file version for the notepad.
    FileVersionInfo myFileVersionInfo =
        FileVersionInfo.GetVersionInfo(Environment.SystemDirectory + "\\Notepad.exe");

    // Print the product build part number.
    textBox1.Text = "Product build part number: " + myFileVersionInfo.ProductBuildPart;
}
Private Sub GetProductBuildPart()
    ' Get the file version for the notepad.
    Dim myFileVersionInfo As FileVersionInfo = _
        FileVersionInfo.GetVersionInfo(Environment.SystemDirectory + "\Notepad.exe")
    
    ' Print the product build part number.
    textBox1.Text = "Product build part number: " & myFileVersionInfo.ProductBuildPart
End Sub

注釈

通常、バージョン番号は "major number.minor number.build number.private part number" と表示されます。 製品バージョン番号は、次のようにバージョン番号を保持する 64 ビット番号です。

このプロパティは、16 ビットの 3 番目のセットを取得します。

適用対象

こちらもご覧ください