unit Business;
interface
uses
SysUtils, Windows, dialogs, winsock, Classes, ComObj, WinInet, Variants;
//得到本机的局域网Ip地址
function IGetLocalIP(): string;
//取本机的计算机名
function IGetComputerName(): string;
//取本机的MAC
function IGetMACAdress(): string;
//屏幕分辨率
function IGetScreenMetrics(): string;
//获取IE版本号
function IGetIEVersion: string;
//获取CPU号
function IGetCPUStr: string;
// 获取内存使用信息
function IGetMemoryStatus: string;
//获取windows版本信息
function IGetOSVersion: string;
implementation
uses NetFunc, WindowFunc;
{---------------------------------------------------}
function IGetLocalIP(): string;
var
LocalIp: string;
begin
try
if GetLocalIP(LocalIp) then
Result := LocalIp;
except
Result := '';
end;
end;
function IGetComputerName(): string;
begin
try
Result := GetComputerName();
except
Result := '';
end;
end;
function IGetMACAdress(): string;
begin
try
Result := GetMACAdress();
except
Result := '';
end;
end;
function IGetScreenMetrics(): string;
begin
try
Result := GetScreenMetrics();
except
Result := '';
end;
end;
function IGetIEVersion(): string;
begin
try
Result := GetIEVersionStr();
except
Result := '';
end;
end;
function IGetCPUStr(): string;
begin
try
Result := GetCPUStr();
except
Result := '';
end;
end;
function IGetMemoryStatus(): string;
begin
try
Result := GetMemoryStatus2();
except
Result := '';
end;
end;
function IGetOSVersion(): string;
begin
try
Result := GetWindowsVersion();
except
Result := '';
end;
end;
end.
Business
最新推荐文章于 2024-09-04 16:20:52 发布