📄 mainform.pas
字号:
unit MainForm;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls,HardwareInfo;
type
TForm11 = class(TForm)
Label1: TLabel;
Label2: TLabel;
Label3: TLabel;
Label4: TLabel;
Label5: TLabel;
Label6: TLabel;
procedure FormCreate(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form11: TForm11;
implementation
{$R *.dfm}
procedure TForm11.FormCreate(Sender: TObject);
var
Info:THardwareInfo;
begin
Info:=THardwareInfo.Create;
Label1.Caption:='网卡物理地址:'+ Info.GetMACAddress();
Label2.Caption:='硬盘物理序列号:'+ Info.GetIDEDiskSerialNumber;
Label3.Caption:='C:盘序列号:'+ Info.GetIDEDiskDriveInfo('C');
Label4.Caption:='CPU 序列号:'+ Info.GetCPUInfo(1);
Label5.Caption:='CPU 频率:'+ Info.GetCPUInfo(2);
Label6.Caption:='CPU 厂商:'+ Info.GetCPUInfo(3);
end;
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -