📄 globalunit.~pas
字号:
unit GlobalUnit;
interface
uses
adodb;
type
PAccessoryInfo=^TAccessoryInfo;
TAccessoryInfo=record
imenutag:integer;////菜单编号
strName:string;//////附件菜单对应的文件名
strPath:string;//////附件菜单对应的文件路径
end;
Tdepart=record
unit_id:integer;//分公司编号
strName:string;//分公司名称
end;
function GetFileName(strPathName:string):string;
function GetFileExt(strFileName:string;var strFileTitle:string):string;
var
G_AdoConnection:TAdoConnection;
OpenFlag:integer;//打开人员选择标记标志:1:会稿人;2:核稿人;3:审稿人;4阅稿人;
///////////////////ent_file表的当前记录数据
unit_id: Integer; //分公司号
iindex: Integer; //文件编号
title: String; //文件标题
path: String; //文件名
creater: String; //文件的创建者
time: TDateTime; //文件的创建时间
iclass: Integer; //文件分类号
memo: String; //文件说明
//////////////////////////////////////////////////
ServerName:string;//服务器机器名
//////////////登录信息记录
g_unit_id:Integer;
g_user_id:String;
g_user_name:string;
g_password:String;
g_level:integer; //权限,能否看所有文件
/////////////////////////////////////////////////
//////////当前文档对应的附件列表
g_accessoryinfo:Array of TAccessoryInfo;
g_ACnt:integer;//附件个数
/////////////////////////////////////////////
///////////树形控件的状态
g_iLevel:integer;
g_itreeindex:integer;
g_iparentindex:integer;
/////////////////////////////////////////////
unit_id_group:Array of Tdepart; // 分公司代码表
unit_id_Cnt:integer; //分公司个数据
implementation
function GetFileName(strPathName:string):string;
var
i:integer;
strPath:string;
begin
strPath:= strPathName;
i:=Pos('\',strPath);
while i<>0 do
begin
delete(strPath,1,i);
i:=Pos('\',strPath);
end;
result:=strPath;
end;
function GetFileExt(strFileName:string;var strFileTitle:string):string;
var
i:integer;
strPath:string;
begin
strPath:= strFileName;
i:=Pos('.',strPath);
while i<>0 do
begin
strFileTitle:=strFileTitle+copy(strPath,1,i);
delete(strPath,1,i);
i:=Pos('.',strPath);
end;
delete(strFileTitle,length(strFileTitle),1);
result:=strPath;
end;
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -