Microsoft
WMIScripting
Library
,
Dengan cara masuk ke menu
Component
-Import
Component
Kemudian Pilih Import type
library
. Perhatikan gambar berikut:
Akan muncul window dialog pilihan, Kemudian Pilih
Import type
library
.kemudian tekan Next sampai muncul lagi windows dialog seperti berikut:
Pilih
Microsoft
WMIScripting
Library
kemudian klik Next - Next dan seterusnnya dan dilanjutkan dengan Proses seperti Proses Install Komponen. Proses ini akan menghasilkan sebuah unit bernama
Langkah Selanjutnya adalah membuat unit seperti berikut ini:
yang ini buat di Copy Paste:
uses
ActiveX,
WbemScripting_TLB;
{$R *.dfm}
Function Baca_SN_Mainboard:string;
var
WMIServices : ISWbemServices;
Root : ISWbemObjectSet;
Item : Variant;
begin
WMIServices := CoSWbemLocator.Create.ConnectServer('.', 'root\cimv2','', '', '', '', 0, nil);
Root := WMIServices.ExecQuery('Select SerialNumber From Win32_BaseBoard','WQL', 0, nil);
Item := Root.ItemIndex(0);
Result:=VarToStr(Item.SerialNumber);
end;
ActiveX,
WbemScripting_TLB;
{$R *.dfm}
Function Baca_SN_Mainboard:string;
var
WMIServices : ISWbemServices;
Root : ISWbemObjectSet;
Item : Variant;
begin
WMIServices := CoSWbemLocator.Create.ConnectServer('.', 'root\cimv2','', '', '', '', 0, nil);
Root := WMIServices.ExecQuery('Select SerialNumber From Win32_BaseBoard','WQL', 0, nil);
Item := Root.ItemIndex(0);
Result:=VarToStr(Item.SerialNumber);
end;
Cara Pakenya tinggal panggil Functionnya misalnya seperti berikut:
procedure TForm1.Button1Click(Sender: TObject);
begin
edit1.Text:=BacaSNMainboard;
end;
begin
edit1.Text:=BacaSNMainboard;
end;
Demikian Postingan saya kali ini tentang Cara Mengetahui Serial Number Motherboard dengan Delphi semoga bermanfaat bagi semua programmer delphi. Jika ada pertanyaan jangan ragu bertanya pada kolom komentar. Jika ada kritik dan saran dipersilahkan juga menulisnya pada kolom komentar.
Salam Delphi.
kalo mau ganti serial motherboard nya gimana?
ReplyDeleteMas, bagaimana cara baca serial number motherboard dengan visual foxpro?
ReplyDeleteDo you understand there is a 12 word sentence you can tell your partner... that will induce deep emotions of love and impulsive attractiveness to you deep inside his chest?
ReplyDeleteBecause deep inside these 12 words is a "secret signal" that triggers a man's impulse to love, worship and guard you with all his heart...
=====> 12 Words Will Trigger A Man's Desire Instinct
This impulse is so hardwired into a man's brain that it will drive him to work better than ever before to make your relationship as strong as it can be.
Matter-of-fact, fueling this all-powerful impulse is so essential to getting the best ever relationship with your man that once you send your man a "Secret Signal"...
...You will instantly notice him expose his soul and heart to you in a way he's never experienced before and he'll see you as the one and only woman in the galaxy who has ever truly interested him.
Cara Mengetahui Serial Number Motherboard Dengan Delphi - Aku Cinta Delphi >>>>> Download Now
ReplyDelete>>>>> Download Full
Cara Mengetahui Serial Number Motherboard Dengan Delphi - Aku Cinta Delphi >>>>> Download LINK
>>>>> Download Now
Cara Mengetahui Serial Number Motherboard Dengan Delphi - Aku Cinta Delphi >>>>> Download Full
>>>>> Download LINK