델파이 실행파일의 버젼정보를 얻을려고 여기 저기서 참고하여 
다음과 같은 함수를 작성하였는데 이상하게 안됩니다. 
정보를 얻을 수가 없습니다.
어디서 잘못한 것인가요?
도와 주세요...
procedure TfrmMain.About1Click(Sender: TObject);
const
  n_Info = 10;
  InfoStr : array [1..n_Info] of String =
    ('CompanyName', 'FileDescription', 'FileVersion', 'InternalName',
     'LegalCopyright', 'LegalTradeMarks', 'OriginalFilename',
     'ProductName', 'ProductVersion', 'Comments');
var
  Info      : String;
  BuffSize : THandle;
  Len : UINT;
  i: LongWord;
  Buff      : PChar;
  Value     : PChar;
begin
  Info := Application.ExeName;
  BuffSize := GetFileVersionInfoSize(PChar(Info),BuffSize);
  if BuffSize > 0 then begin
    Buff := AllocMem(BuffSize);
    GetFileVersionInfo(PChar(Info),0,BuffSize,Buff);
    Info := Info + ':';
    for i := 1 to n_Info do
      if VerQueryValue(Buff,PChar('StringFileInfo 40904E4'+
                       InfoStr[i]), Pointer(Value), Len) then
        Info := Info + #13 + InfoStr[i] + '=' + Value;
    FreeMem(Buff,BuffSize);
    ShowMessage (Info);
  end else
    ShowMessage ('No FileVersionInfo found');
end;
			 
	
	
    
    
	
	
    
    
    
우연히..
도움이 되셨으면 합니다.
procedure TForm1.Button6Click(Sender: TObject);
const
InfoNum = 10;
InfoStr : array [1..InfoNum] of String =
('CompanyName', 'FileDescription', 'FileVersion', 'InternalName',
'LegalCopyright', 'LegalTradeMarks', 'OriginalFilename',
'ProductName', 'ProductVersion', 'Comments');
var
S : String;
n, Len, i : Integer;
Buf : PChar;
Value : PChar;
FileNames : String;
begin
if not OpenDialog1.Execute then System.Exit;
FileNames := OpenDialog1.FileName;
S := FileNames;//Application.ExeName;
n := GetFileVersionInfoSize(PChar(S),n);
if n > 0 then begin
Buf := AllocMem(n);
Memo1.Lines.Add('FileVersionInfoSize='+IntToStr(n));
GetFileVersionInfo(PChar(S),0,n,Buf);
for i:=1 to InfoNum do
if VerQueryValue(Buf,PChar('StringFileInfo