CnPack Forum » CnPack IDE 专家包(CnWizards) » 格式化出错. 代码中包含窗体动态生成.


2015-9-11 15:29 fxerp@qq.com
格式化出错. 代码中包含窗体动态生成.

procedure CreateProgressForm;
  begin
    ProgressForm := Forms.TForm.Create(nil);
    with ProgressForm do
    begin
      Font.Name := '宋体';
      Font.Size := 10;
      BorderStyle := bsNone;
      Width := 280;
      Height := 120;
      BorderWidth := 1;
      Color := clBackground;
      Position := poOwnerFormCenter;
    end;
    Panel := TPanel.Create(ProgressForm);
    with Panel do { Create Panel }
    begin
      Parent := ProgressForm;
      Align := alClient;
      BevelInner := bvNone;
      BevelOuter := bvNone;
      Caption := '';
    end;

    Prompt := TLabel.Create(Panel);
    with Prompt do { Create Label }
    begin
      Parent := Panel;
      Left := 20;
      Top := 25;
      Caption := '正在启动Excel,请稍候……';
    end;

    progressBar := TProgressBar.Create(panel);
    with ProgressBar do { Create ProgressBar }
    begin
      Step := 1;
      Parent := Panel;
      Smooth := true;
      Left := 20;
      Top := 50;
      Height := 18;
      Width := 260;
    end;

    Button := TButton.Create(Panel);
    with Button do { Create Cancel Button }
    begin
      Parent := Panel;
      Left := 115;
      Top := 80;
      Caption := '关闭';
    end;
    ReSetObjEvent(@@Button.OnClick, @ButtonClick, Button);
    ProgressForm.FormStyle := fsStayOnTop;
    skn1.SkinForm(ProgressForm.Handle);
    ProgressForm.Show;
    ProgressForm.Update;
  end;

2015-9-15 15:18 Passion
经过查证,是Align这种声明的关键字导致的问题,我们将在下一每日构建版里修正。

2015-9-17 14:53 Passion
770已修正:

[url]http://www.cnpack.org/downbuilds.php[/url]

页: [1]


Powered by Discuz! Archiver 5.0.0  © 2001-2006 Comsenz Inc.