AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Motherboard SN

 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
Maja
Guest





PostPosted: Mon Nov 19, 2007 8:03 am    Post subject: Motherboard SN Reply with quote

is there anyway to get the Serial No of Motherboard with AHK.

Thanks.
Back to top
Sean



Joined: 12 Feb 2007
Posts: 1397

PostPosted: Mon Nov 19, 2007 12:04 pm    Post subject: Reply with quote

WMI with Win32_BaseBoard.
Back to top
View user's profile Send private message
Guest






PostPosted: Mon Nov 19, 2007 12:05 pm    Post subject: Re: Motherboard SN Reply with quote

Question
Back to top
AHKpandit
Guest





PostPosted: Tue Nov 20, 2007 6:41 am    Post subject: Reply with quote

Sean wrote:
WMI with Win32_BaseBoard.


Can you give me an example?
I am new I cannot understand you. Embarassed

Thanks.
Back to top
Sean



Joined: 12 Feb 2007
Posts: 1397

PostPosted: Tue Nov 20, 2007 6:59 am    Post subject: Reply with quote

Read this page before using it:
http://www.autohotkey.com/forum/topic25362.html&highlight=wmi

Code:
COM_Init()
psvc := COM_GetObject("winmgmts:{impersonationLevel=impersonate}!" . "\\.\root\cimv2")
pset := COM_Invoke(psvc, "ExecQuery", "SELECT * FROM " . "Win32_BaseBoard")
penm := COM_Invoke(pset, "_NewEnum")
If   COM_Enumerate(penm, pobj) = 0
   SerialNumber := COM_Invoke(pitm:=COM_Invoke(pprs:=COM_Invoke(pobj, "Properties_"), "Item", "SerialNumber"), "Value"), COM_Release(pitm), COM_Release(pprs), COM_Release(pobj)
COM_Release(penm)
COM_Release(pset)
COM_Release(psvc)
COM_Term()

MsgBox, % SerialNumber
Back to top
View user's profile Send private message
AHKpandit
Guest





PostPosted: Tue Nov 20, 2007 10:58 am    Post subject: Reply with quote

Hello Sean thanks for help I try this but I am receiving this message.

I am using latest version of AHK
Back to top
hotzenpl0tz



Joined: 22 Oct 2007
Posts: 11

PostPosted: Tue Nov 20, 2007 1:43 pm    Post subject: Reply with quote

You need COM.ahk.
http://www.autohotkey.com/forum/viewtopic.php?t=22923

You will have to include it in your script with:
#include COM.ahk
Back to top
View user's profile Send private message
Sean



Joined: 12 Feb 2007
Posts: 1397

PostPosted: Tue Nov 20, 2007 2:54 pm    Post subject: Reply with quote

It's the reason why I told "read the linked page first". You can use it via #Include as hotzenpl0tz said or Standard Library.
Back to top
View user's profile Send private message
AHKpandit
Guest





PostPosted: Fri Nov 23, 2007 4:05 am    Post subject: Reply with quote

@Sean
Can you get Processor SN?
Back to top
Sean



Joined: 12 Feb 2007
Posts: 1397

PostPosted: Fri Nov 23, 2007 4:49 am    Post subject: Reply with quote

AHKpandit wrote:
Can you get Processor SN?

Sure. Read:
http://www.autohotkey.com/forum/viewtopic.php?t=14716&postdays=0&postorder=asc&start=15
or
http://www.autohotkey.com/forum/viewtopic.php?t=5763&postdays=0&postorder=asc&start=105
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group