FileVersionInfo.ProductMinorPart Właściwość

Definicja

Pobiera pomocniczą część numeru wersji produktu, z który jest skojarzony plik.

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

Wartość właściwości

Wartość reprezentująca pomocniczą część numeru wersji produktu lub null jeśli plik nie zawiera informacji o wersji.

Przykłady

Poniższe przykładowe wywołania GetVersionInfo w celu pobrania FileVersionInfo elementu dla Notatnika. Następnie drukuje element ProductMinorPart w polu tekstowym. W tym kodzie przyjęto założenie textBox1 , że zostało utworzone wystąpienie.

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

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

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

Uwagi

Zazwyczaj numer wersji jest wyświetlany jako "numer główny.numer pomocniczy.numer kompilacji.prywatny numer części". Numer wersji produktu to 64-bitowy numer, który zawiera numer wersji w następujący sposób:

Ta właściwość pobiera drugi zestaw 16 bitów.

Dotyczy

Zobacz też