<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <br>
    <div class="moz-cite-prefix">Le 06/11/2013 14:41, Anton Kavalenka a
      écrit :<br>
    </div>
    <blockquote cite="mid:527A46F3.6020600@tut.by" type="cite">
      <meta content="text/html; charset=ISO-8859-1"
        http-equiv="Content-Type">
      <font face="Liberation Sans">The unit versionresource</font> is
      part of package fcl-res <br>
    </blockquote>
    I already use it for Linux with a Linux executable file<br>
    <blockquote cite="mid:527A46F3.6020600@tut.by" type="cite"> <br>
      Unit allow x-platform version resource extraction and parsing.<br>
      rsrc:=TVersionResource.Create;<br>
      Stream := TResourceStream.CreateFromID(<b><big>hMod</big></b>, 1,
      PChar(RT_VERSION));<br>
    </blockquote>
    What's <b><big>hMod </big></b>stands for ? Looks like a pointer of
    so (PtrUint)<br>
    <blockquote cite="mid:527A46F3.6020600@tut.by" type="cite">
      rsrc.SetCustomRawDataStream(Stream);<br>
       with res do<br>
            case it of<br>
            vsFileVersion:<br>
             
Result:=format('%d.%d.%d.%d',[FileVersion[0],FileVersion[1],FileVersion[2],FileVersion[3]]);<br>
            vsProductVersion:<br>
             
Result:=format('%d.%d.%d.%d',[ProductVersion[0],ProductVersion[1],ProductVersion[2],ProductVersion[3]]);<br>
            end;<br>
      <br>
      regards,<br>
      Anton<br>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">--
_______________________________________________
Lazarus mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Lazarus@lists.lazarus.freepascal.org">Lazarus@lists.lazarus.freepascal.org</a>
<a class="moz-txt-link-freetext" href="http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus">http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>