Lazarus
Programming => Operating Systems => Topic started by: Wargan on May 02, 2017, 06:47:27 am
-
Hello!
What code should I use to find out the following PC settings?
- The amount of RAM
- Video memory: vendor/size
- Windows username
- Size of the hard drive
- Is the installation disk a hard drive or a USB flash drive? :)
p.s. I'm programming under Windows.
-
Through WMI? Like this: http://stackoverflow.com/questions/6383598/delphi-how-to-get-total-disk-space-of-windows-drive .
-
Hm. Directly through the registry, maybe? HKEY_LOCAL_MACHINE\HARDWARE\ and then DESCRIPTION\ and sub keys etc. Easy.
-
You could try WMI Delphi Code Creator, I've used it in the past to get system serial numbers/asset details.
https://theroadtodelphi.com/wmi-delphi-code-creator/ (https://theroadtodelphi.com/wmi-delphi-code-creator/)
-
You could try WMI Delphi Code Creator, I've used it in the past to get system serial numbers/asset details.
https://theroadtodelphi.com/wmi-delphi-code-creator/ (https://theroadtodelphi.com/wmi-delphi-code-creator/)
WMI will work, as i wrote before, but direct registry access is much quicker and generates less code.
-
https://theroadtodelphi.com/wmi-delphi-code-creator/ (https://theroadtodelphi.com/wmi-delphi-code-creator/)
Site doesn't work >:(
-
sorry, did not check the download link, you may have to Google WMI Delphi Code Creator download or try CNET etc
-
The site DOES work. Use ABP to skip all the sh*t in between.
-
projects repo is at https://github.com/RRUZ/wmi-delphi-code-creator
it has download links for the binaries as well.
-
Many thanks to all!
I downloaded the WMI Delphi Code Generator from here (http://www.softpedia.com/get/Programming/Coding-languages-Compilers/WMI-Delphi-Code-Creator.shtml).
After installation in the settings you can specify generation of code for FreePascal.