Jump to content

Regwrite


Gerry
 Share

Recommended Posts

:whistle: Hi All

I am busy with a program to do a hardware and software audit of the company assets.

Part of this means that a company asset number must be recorded as well for each PC and printer.

I can get monitor and pc serial number, models, etc. Of course the asset number will be have to be entered manually

I created a Gui to easily record these asset numbers. I then want to write it to the registry, if I in future have to re-audit, I can query the registry.

For the PC base this will work fine but for the monitor, I would compare the previously recorded serial number to the value read, which should tell me if the monitor was changed since the previous audit.

Sounds easy? I write to the registry, this can then be verified, all ok. On rebooting the PC, the entries are all wiped out!

I am writing to "HKLM\Hardware\AUDIT", any ideas why this happens and how I can overcome this problem?

Regards

Gerry

Link to comment
Share on other sites

Hi,

why do you write it to the reg? Why not saving all the files in a share which can be backuped so that even a reinstall of the pc wouldn't erase the data?

Or aa usb device ?

So long,

Mega

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

From MSDN:

The hardware archive root key in the registry that is a superset of the memory-resident hardware tree. The hardware tree contains information only about those devices currently detected and running in the system.

Create your key under the HKLM\Software key and it'll have a better chance of being there when you reboot. You might want to visit the MSDN site to get a better understand of the registry. It's one of those things you typically don't want to go mucking around with if you don't know what your doing.

Edited by PaulIA
Auto3Lib: A library of over 1200 functions for AutoIt
Link to comment
Share on other sites

I suppose mucking around with the registry could be a loaded gun!

That is why I would like to create a new key, thanks for the tip, will check MSDN out.

Gerry

can get monitor and pc serial number, models, etc. Of course the asset number will be have to be entered manually

Just an idea, the company that I work for only buy Dell Computers, so I don't know if you can do the same thing with others brand. On the Dell computers you can run the Bios update cd to add an Asset Tag to the BIOS and with AutoIt you will be able to get the asset tag from the Bios. This way even if the user computer hard disk crash the Asset # still untouch on the computers Bios beside the registry key will be gone. Edited by Danny35d
AutoIt Scripts:NetPrinter - Network Printer UtilityRobocopyGUI - GUI interface for M$ robocopy command line
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...