[Lazarus] Build Number
Kjow
antispammoni at gmail.com
Fri Jul 23 10:12:24 CEST 2010
2010/7/23 Paul Ishenin <ip at kmiac.ru>:
> This constanst is stored as a resource of your application. You can read it
> by accessing this resource.
>
> I attached a small utility unit which helps with the version info
> extraction.
>
> Here is a small example of how to use it (add vinfo and versiontypes units
> to your uses section):
>
> procedure TForm1.Button1Click(Sender: TObject);
>
> function ProductVersionToString(PV: TFileProductVersion): String;
> begin
> Result := Format('%d.%d.%d.%d', [PV[0],PV[1],PV[2],PV[3]])
> end;
>
> var
> Info: TVersionInfo;
> begin
> Info := TVersionInfo.Create;
> Info.Load(HINSTANCE);
> ShowMessage(ProductVersionToString(Info.FixedInfo.FileVersion));
> ShowMessage(ProductVersionToString(Info.FixedInfo.ProductVersion));
> Info.Free;
> end;
>
> Best regards,
> Paul Ishenin.
Thank you, but my Lazarus (r26732M) can't find vinfo unit.
Other question: Is this procedure multiplatform compatible? ( => Does
it work on Linux?)
Regards,
Kjow
More information about the Lazarus
mailing list