Ver Mensaje Individual
  #9  
Antiguo 03-10-2005
CRIS CRIS is offline
Miembro
 
Registrado: jul 2003
Posts: 63
Reputación: 21
CRIS Va por buen camino
Me funciona solo esto y gracias a los dos por ayudarme.

Código Delphi [-]
 procedure TForm1.SpeedButton1Click(Sender: TObject);
 
   function GetAppVersion:string;
   var
     Size, Size2: DWord;
     Pt, Pt2: Pointer;
   begin
     Size := GetFileVersionInfoSize(PChar (ParamStr (0)), Size2);
     if Size > 0 then
     begin
       GetMem (Pt, Size);
       try
         GetFileVersionInfo (PChar (ParamStr (0)), 0, Size, Pt);
         VerQueryValue (Pt, '\', Pt2, Size2);
         with TVSFixedFileInfo (Pt2^) do
         begin
           Result:= ' Ver '+
             IntToStr (HiWord (dwFileVersionMS)) + '.' +
             IntToStr (LoWord (dwFileVersionMS)) + '.' +
             IntToStr (HiWord (dwFileVersionLS)) + '.' +
             IntToStr (LoWord (dwFileVersionLS));
         end;
       finally
         FreeMem (Pt);
       end;
     end;
   end;
 
 begin
   label1.Caption:=GetAppVersion;
 end;

Última edición por dec fecha: 03-10-2005 a las 15:00:14. Razón: ¡¡Encerrad el código fuente entre las etiquetas [DELPHI] ... [/DELPHI]!!
Responder Con Cita