oleregister6.pas

来自「是一个delphi的流程制作软件」· PAS 代码 · 共 71 行

PAS
71
字号

//========================= OLE UI UTILITIES ===================================
//
// This is a component editor for the OleUIPropmptUser dialog
//
// Grahame Marsh
// Freeware for UNDU - you get it for free I make no promises
// gsmarsh@aol.com
//------------------------------------------------------------------------------

{$I OLE.INC}

unit OleRegister6;

interface

uses
  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
  ExtCtrls, StdCtrls, Buttons, ComCtrls,

  OleDlgs;

type
  TOleUserForm = class(TForm)
    PageControl: TPageControl;
    StandardTabSheet: TTabSheet;
    GroupBox2: TGroupBox;
    CaptionEdit: TEdit;
    OKBtn: TBitBtn;
    CancelBtn: TBitBtn;
    StyleRB: TRadioGroup;
    Label1: TLabel;
    Label2: TLabel;
    ParamEdit: TEdit;
  private
    FComponent : TComponent;
  public
    property Dialog : TComponent read FComponent write FComponent;
    procedure Initialise;
    procedure Finalise;
  end;

var
  OleUserForm: TOleUserForm;

implementation

{$R *.DFM}

procedure TOleUserForm.Initialise;
begin
  with FComponent as TOlePromptUserDialog do
  begin
    CaptionEdit.Text := Caption;
    ParamEdit.Text := Param;
    StyleRB.ItemIndex := ord (UserStyle)
  end
end;

procedure TOleUserForm.Finalise;
begin
  with FComponent as TOlePromptUserDialog do
  begin
    Caption := CaptionEdit.Text;
    Param := ParamEdit.Text;
    UserStyle := TOlePromptUserStyle (StyleRB.ItemIndex)
  end
end;

end.

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?