|
-
Jan 22nd, 2010, 02:17 AM
#24
Re: How can know Manufacture Hardware ID (Serial Number) of Disk or MotherBord etc
as this is an old thread resurrected, you should make clear who you are addressing, people who posted in this thread originally may not still be active in the forum
i have tested wmi in both vista and windows7 (home premium) as a limited user, works in both, but the return strings have to be decoded
in vista the return is in ascii
but in widows 7 the return is a hex string
in either case it easy to process the return to get the correct value
should be able to figure from the length of the return whether it is ascii or hex
as admin user the correct value was returned directly from the wmi query in vista, have not tried that yet in windows 7
i have also made an api version that asks for elevation, then it works correctly with admin password provided
i do my best to test code works before i post it, but sometimes am unable to do so for some reason, and usually say so if this is the case.
Note code snippets posted are just that and do not include error handling that is required in real world applications, but avoid On Error Resume Next
dim all variables as required as often i have done so elsewhere in my code but only posted the relevant part
come back and mark your original post as resolved if your problem is fixed
pete
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|