procedure TForm1.Button1Click(Sender: TObject); var mm:TRegistry; cpu:string; begin mm:=TRegistry.Create; with mm do begin RootKey:=HKEY_LOCAL_MACHINE; if OpenKeyReadOnly(\'\Hardware\Description\System\CentralProcessor\0\') then begin cpu := ReadString(\'ProcessorNameString\'); Memo1.Lines.Add(\'处理器:\'+cpu); end; end; Memo1.Lines.Add(\'系统版本:\'+TOSVersion.ToString); end;
需要引用 System.Win.Registry单元
请发表评论