缘 缘来一家人 Unregistered / Unconfirmed GUEST, unregistred user! 2003-07-30 #1 如何定义全局变量数组,一维的就行了,要整个工程 中都可以 type tlimit=array [1..4] of Integer ; 要放哪
W wwolf Unregistered / Unconfirmed GUEST, unregistred user! 2003-07-30 #2 unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs; type tlimit=array [1..4] of Integer ; TForm1 = class(TForm) private { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} end. 要用的地方都要Uses Unit1
unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs; type tlimit=array [1..4] of Integer ; TForm1 = class(TForm) private { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} end. 要用的地方都要Uses Unit1
C chinawjy Unregistered / Unconfirmed GUEST, unregistred user! 2003-07-30 #4 那何必搞个Form呢?直接在系统中新建一个Unit,比如叫SysInfo;看看这个行不行。 unit SysInfo; interface uses SysUtils; var tlimit :array [1..4] of Integer; LoginResult :Boolean= False; CurUser :String; //当前用户 UserName :String; //用户名字 MainRight :String; //系统菜单权限 implementation end.
那何必搞个Form呢?直接在系统中新建一个Unit,比如叫SysInfo;看看这个行不行。 unit SysInfo; interface uses SysUtils; var tlimit :array [1..4] of Integer; LoginResult :Boolean= False; CurUser :String; //当前用户 UserName :String; //用户名字 MainRight :String; //系统菜单权限 implementation end.