Main.pas
上传用户:gyjjlc
上传日期:2013-03-29
资源大小:2124k
文件大小:1k
源码类别:

多显示器编程

开发平台:

C++ Builder

  1. unit Main;
  2. interface
  3. uses
  4. Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
  5. StdCtrls, PBFolderDialog;
  6. type
  7.   TForm1 = class(TForm)
  8.     Edit1: TEdit;
  9.     Edit2: TEdit;
  10.     SelectFolder: TButton;
  11.     Label1: TLabel;
  12.     Label2: TLabel;
  13.     PBFolderDialog1: TPBFolderDialog;
  14.     procedure SelectFolderClick(Sender: TObject);
  15.   private
  16.     { Private declarations }
  17.   public
  18.     { Public declarations }
  19.   end;
  20. var
  21. Form1: TForm1;
  22. implementation
  23. {$R *.DFM}
  24. procedure TForm1.SelectFolderClick(Sender: TObject);
  25. begin
  26. if PBFolderDialog1.Execute then
  27. begin
  28. Edit1.Text := PBFolderDialog1.Folder;
  29. Edit2.Text := PBFolderDialog1.DisplayName;
  30. end;
  31. end;
  32. end.