ShowRemoveRedeyeDlg example for Delphi

procedure TForm1.ShowRemoveRedeyeDlg1Click(Sender: TObject); 
var
   nRet: L_INT; 
begin
   LEADDlgImgDoc1.ZoomToFit:= False; 
   LEADDlgImgDoc1.DlgFlags:= DLG_REMOVEREDEYE_SHOW_PREVIEW Or
                         DLG_REMOVEREDEYE_SHOW_TOOL_ZOOMLEVEL; 

   LEADDlgImgDoc1.LEADImage:= LEADImage1; 
   LEADDlgImgDoc1.LEADDlgService:= LEADDlgService1; 
   LEADDlgImgDoc1.EnableMethodErrors:= False; 
    LEADDlgImgDoc1.ShowHelpButton:= True; 

   nRet:= LEADDlgImgDoc1.ShowRemoveRedeyeDlg ( Self ); 
   if ( nRet = SUCCESS_DLG_OK ) then
   begin
      LEADImage1.RemoveRedeye ( LEADDlgImgDoc1.NewColor, LEADDlgImgDoc1.Threshold, LEADDlgImgDoc1.Lightness ); 
   end; 
end; 
procedure TForm1.LEADDlgImgDoc1DlgHelp (uDialogID: Cardinal); 
begin
   case ( uDialogID ) of

      DLG_HELP_REMOVEREDEYE: 
         ShowMessage( 'Help from Remove Red eye dialog' ); 

      DLG_HELP_SMOOTH: 
         ShowMessage( 'Help from Smooth dialog' ); 

      DLG_HELP_LINEREMOVE: 
         ShowMessage( 'Help from Line-Remove dialog' ); 

      DLG_HELP_BORDERREMOVE: 
         ShowMessage( 'Help from Border-Remove dialog' ); 

      DLG_HELP_INVERTEDTEXT: 
         ShowMessage( 'Help from Inverted-Text dialog' ); 

      DLG_HELP_DOTREMOVE: 
         ShowMessage( 'Help from Dot-Remove dialog' ); 

      DLG_HELP_HOLEPUNCHREMOVE: 
         ShowMessage( 'Help from Hole-Punch-Remove dialog' ); 
   end; 
end;