ShowOpenDlg example for Delphi

procedure TForm1.ShowOpenDlg1Click(Sender: TObject); 
var
   nRet: L_INT; 
begin

   LEADDlgFile1.DialogTitle:= 'LEADTOOLS Open dialog box'; 
   LEADDlgFile1.InitialDir:= 'c:\images'; 
   LEADDlgFile1.DlgFileFlags:= 0; 
   LEADDlgFile1.PreviewEnabled:= True; 
   LEADDlgFile1.ShowLoadOptions:= False; 
   LEADDlgFile1.LoadRotated:= False; 
   LEADDlgFile1.LoadCompressed:= False; 
   LEADDlgFile1.LoadPasses:= 0; 
   LEADDlgFile1.MaxFileSize:= 0; 
   LEADDlgFile1.MaxFileTitleSize:= 0; 

   LEADDlgFile1.DlgFlags:= DLG_OPEN_SHOW_PROGRESSIVE     +
                           DLG_OPEN_SHOW_MULTIPAGE       +
                           DLG_OPEN_SHOW_LOADROTATED     +
                           DLG_OPEN_SHOW_LOADCOMPRESSED  +
                           DLG_OPEN_SHOW_FILEINFO        +
                           DLG_OPEN_SHOW_PREVIEW         +
                           DLG_OPEN_SHOW_DELPAGE         +
                           DLG_OPEN_VIEWTOTALPAGES; 

   LEADDlgFile1.LEADImage:= LEADImage1; 
   nRet:= LEADDlgFile1.ShowOpenDlg ( Self ); 
   if ( nRet = SUCCESS_DLG_OK ) then
   begin
      LEADImage1.Load ( LEADDlgFile1.FileName, 0, LEADDlgFile1.PageNumber, 1 ); 
      Edit1.Text:= LEADDlgFile1.FileName
      Edit2.Text:= LEADDlgFile1.FileTitle
      Edit3.Text:= IntToStr ( LEADDlgFile1.PageNumber ); 
   end; 
end;