?? readcomm.~dpr
字號:
library readcomm;
uses
SysUtils,Inifiles,Classes;
{$R *.res}
var inifile:Tinifile;
function GetValue(Num:integer): integer; stdcall;
begin
If Num=1 then GetValue :=inifile.ReadInteger('com1','value',0);
If Num=2 then GetValue :=inifile.ReadInteger('com2','value',0);
end;
function GetStatus(Num:integer): integer; stdcall;
begin
If Num=1 then GetStatus:=inifile.ReadInteger('com1','status',0);
If Num=2 then GetStatus:=inifile.ReadInteger('com2','status',0);
end;
function SetCut1(Cut:integer): integer; stdcall;
begin
inifile.WriteInteger('com1','inew',cut);
inifile.UpdateFile;
SetCut1:=cut;
end;
function SetCut2(Cut:integer): integer; stdcall;
begin
inifile.WriteInteger('com2','inew',cut);
inifile.UpdateFile;
SetCut2:=cut;
end;
exports
GetValue,
GetStatus,
SetCut1,
SetCut2;
begin
inifile:=Tinifile.Create('inicomm.ini');
end.
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -