├── .gitignore ├── CHANGELOG.md ├── Demos ├── FMX │ ├── FMXDemo.dpr │ ├── FMXDemo.dproj │ ├── FMXDemo.manifest │ ├── FMXDemo_Icon.ico │ ├── FmFMXDemo.fmx │ ├── FmFMXDemo.pas │ ├── MainIcon.rc │ ├── MainIcon.res │ ├── Manifest.rc │ └── Manifest.res ├── ReadMe.txt └── VCL │ ├── FmDemo.dfm │ ├── FmDemo.pas │ ├── MainIcon.rc │ ├── MainIcon.res │ ├── Manifest.rc │ ├── Manifest.res │ ├── SysInfoDemo.bdsproj │ ├── SysInfoDemo.cfg │ ├── SysInfoDemo.dof │ ├── SysInfoDemo.dpr │ ├── SysInfoDemo.dproj │ ├── SysInfoDemo.manifest │ └── SysInfoDemo_Icon.ico ├── DevTools └── Release.bat ├── Docs ├── Acknowledgements.md ├── Documentation.URL ├── MPL-2.0.txt ├── PreSVNHistory.txt └── SysInfo-SF-ReadMe.txt ├── PJSysInfo.pas └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | # .gitignore file based on 2 | # https://github.com/github/gitignore/blob/main/Delphi.gitignore 3 | # License: CC0 4 | 5 | # ---------------------------------- 6 | # Delphi compiler-generated binaries 7 | # ---------------------------------- 8 | 9 | *.exe 10 | *.dll 11 | *.bpl 12 | *.bpi 13 | *.dcp 14 | *.so 15 | *.apk 16 | *.drc 17 | *.map 18 | *.dres 19 | *.rsm 20 | *.tds 21 | *.dcu 22 | *.lib 23 | *.a 24 | *.o 25 | *.ocx 26 | *.res 27 | *.tlb 28 | *.obj 29 | 30 | # -------------------------------------------- 31 | # Delphi autogenerated files (duplicated info) 32 | # -------------------------------------------- 33 | 34 | *.cfg 35 | *.hpp 36 | #Resource.rc 37 | 38 | # ---------------------------------------------- 39 | # Delphi designer / tools files (not being used) 40 | # ---------------------------------------------- 41 | 42 | # diagram portfolio file 43 | *.dpp 44 | 45 | # visual live bindings 46 | *.vlb 47 | 48 | # deployment manager 49 | *.deployproj 50 | 51 | # --------------------------------------- 52 | # Delphi local files (user-specific info) 53 | # --------------------------------------- 54 | 55 | *.local 56 | *.identcache 57 | *.projdata 58 | *.tvsconfig 59 | *.dsk 60 | 61 | # -------------------------- 62 | # Delphi history and backups 63 | # -------------------------- 64 | 65 | __history/ 66 | __recovery/ 67 | *.~* 68 | 69 | # ------------- 70 | # Release files 71 | # ------------- 72 | 73 | Release 74 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Change Log for System Information Unit 2 | 3 | ## v5.32.0 of 02 April 2025 4 | 5 | + Added new TPJBiosInfo class that provides access to some of the information contained in the host computer's BIOS, providing that the BIOS supports the SMBIOS reference specification v2.0 or later. 6 | + Updated both the VCL and FMX demo programs to add a new tab that displays the results of calling each of the methods of TPJBiosInfo. 7 | + Removed return values from Exit statements in the PJSysInfo unit to enable compilation with older Delphis. 8 | + Fixed bug in TPJOSInfo.ProductName where a format string had an incorrect number of placeholders for version numbers. 9 | + Fixed spelling mistake in the VCL demo project's TPJComputerInfo tab. 10 | + Changed the descriptive text on the TPJComputerInfo tab of the VCL demo program to refer to the each method's name rather than describing the purpose of the method. 11 | + Updated documentation: 12 | + Updated `README.md` re the addition of the TPJBiosInfo class. 13 | + Updated copyright dates in `README.md` to include 2025. 14 | + Acknowleged the author of some C code that formed the basis of some of Pascal code in TPJBiosInfo. 15 | 16 | ## v5.31.0 of 01 January 2025 17 | 18 | + Updated TPJOSInfo to detect Windows builds and revisions released in October to December 2024: 19 | + Added support for detecting Windows Server 2025: added added osWinSvr2025 20 | to TPJOSInfoProduct enumeration. 21 | + Added support for detecting any Windows Server versions later than Windows Server 2025: added osWinSvrLater to TPJOSInfoProduct 22 | enumeration. 23 | + Updated Windows 10 21H2 public release build information. 24 | + Updated Windows 10 22H2 public release, release preview & beta channel build information. 25 | + Updated Windows 11 21H2 public release build information. 26 | + Updated Windows 11 22H2 public release build information. 27 | + Updated Windows 11 23H2 public release & release preview channel build information. 28 | + Updated Windows 11 24H2 public release, release preview & canary channel build information. 29 | + Updated Windows 11 Future component updates in dev & beta channel build information. 30 | + Modified code that detects Windows Server 2022. 31 | + Fixed uninitialised variable error in a helper function. 32 | + Updated the demo projects to display the newly added osWinSvr2025 & osWinSvrLater values of the TPJOSProduct enumeration that identify Windows Server 2005 and later Windows Server OSs. 33 | 34 | ## v5.30.0 of 06 October 2024 35 | 36 | + Updated PRODUCT_xxx constant definitions to include all those defined in the Windows 11 24H2 SDK. 37 | + Made the code in TPJOSInfo that gets the operating system edition name more robust. If the name can't be found in lookup tables then the registry is now checked too. 38 | + Added new TPJOSInfo.BuildBranch method that returns the name of the repository branch from which the OS was released. 39 | + Added new TPJOSInfo.DigitalProductID method that retrieves the OS's digital product ID. 40 | + Added new methods to TPJOSInfo that get additional information about the Windows 10 & 11 "version" numbers (e.g. 1507 or 23H2). The methods are IsWindows10VersionOrLater, IsWindows11VersionOrLater, Windows10PlusVersion and Windows10PlusVersionName. 41 | + Some TPJOSInfo and TPJComputerInfo methods were inlined. 42 | + Refactored out a "with" statement. 43 | + Removed commented out code from the PJSysInfo unit. 44 | + Updated the demo projects: 45 | + The FMX demo project was modified for compilation with Delphi 12 by updating the demo project options. main form properties and required units. (All changes were automatically created by the Delphi 12 IDE.) 46 | + Both the VCL and FMX projects were updated to demonstrate all the new TPJSysInfo methods added in this release. 47 | + Fixed a bug in the FMX demo program where string grids were not resizing with the main window. 48 | + Updated `.gitignore` to ignore the `.res` files generated by Delphi 12. 49 | 50 | ## v5.29.0 of 01 October 2024 51 | 52 | + Updated TPJOSInfo to detect various Windows 10 and 11 builds and revisions released in July to September 2024: 53 | + Updated Windows 10 21H2 public release build information. 54 | + Updated Windows 10 22H2 public release & release preview & beta channel build information. 55 | + Updated Windows 11 21H2 public release build information. 56 | + Updated Windows 11 22H2 public release & release preview channel build information. 57 | + Updated Windows 11 23H2 public release & release preview channel build information. 58 | + Updated Windows 11 24H2 public release, release preview, dev & canary channel build information. 59 | + Updated Windows 11 Future component updates in dev & beta channel build information. 60 | + Removed numerous expired Windows 11 Dev, Beta and Canary Channel builds. 61 | + Fixed bug where Future Component in Dev Channel Builds were never being found. 62 | + Updated documentation comments re expired versions and product lifecycle. 63 | + Renamed some constant names for consistency and readability. 64 | 65 | ## v5.28.0 of 01 July 2024 66 | 67 | + Updated TPJOSInfo to detect various Windows 10 and 11 builds and revisions released in April to June 2024: 68 | + Windows 10 21H2 public release changes 69 | + Windows 10 22H2 public release, release preview & beta channel changes 70 | + Windows 11 21H2 public release changes 71 | + Windows 11 22H2 public release & release preview channel changes 72 | + Windows 11 23H2 public release & release preview channel changes 73 | + Windows 11 24H2 public release, release preview, dev & canary channel changes & corrections 74 | + Windows 11 future component update beta channel changes 75 | + Windows 11 future component update dev channel information added 76 | + Added missing version number and release date information to `CHANGLOG.md` relating to release v5.27.0. 77 | 78 | ## v5.27.0 of 01 April 2024 79 | 80 | + Updated TPJOSInfo to detect various Windows 10 and 11 builds and revisions released in January to March 2024: 81 | + Windows 10 version 21H2 public release changes 82 | + Windows 10 version 22H2 public release and release preview channel changes 83 | + Windows 11 21H2, 22H2 & 23H2 public release changes 84 | + Windows 11 22H2 & 23H2 release preview channel changes 85 | + Windows 11 Moment 5 release 86 | + Windows 11 future component update changes 87 | + Windows 11 Dev channel 22H2 changes 88 | + Dropped support Windows 11 22H2 Canary channel builds now all are expired 89 | + Windows 11 23H2 Cannary channel changes 90 | + New Windows 11 24H2 Dev & Canary channel builds 91 | + Fixed bug re incorrect future component update build number 92 | + Fixed error in `CHANGLOG.md` relating to release v5.26.0. 93 | 94 | ## v5.26.0 of 02 January 2024 95 | 96 | + Updated TPJOSInfo to detect various Windows 10 and 11 builds and revisions released in December 2023: 97 | + Windows 10 version 21H2 & 22H2 public release revisions. 98 | + Windows 11 21H2, 22H2 & 23H2 public release revisions. 99 | + Windows 11 Dev & Canary channel revisions. 100 | + Windows Future Component Update builds. 101 | + Brought testing information up to date in `README.md` and `Docs/ReadMe.txt`. 102 | + Updated license copyright date in `README.md` and `PJSysInfo.pas`. 103 | + Fixed some errors in `CHANGELOG.md`. 104 | 105 | ## v5.25.0 of 03 December 2023 106 | 107 | + Updated TPJOSInfo to detect various Windows 10 and 11 builds and revisions released in November 2023: 108 | + Windows 10 version 21H2 & 22H2 public & release preview revisions. 109 | + Windows 11 21H2, 22H2 & 23H2 public, beta & release preview channel revisions. 110 | + Windows 11 Dev & Canary channel revisions. 111 | + Windows 11 Future Component Update Beta builds. 112 | 113 | ## v5.24.0 of 03 November 2023 114 | 115 | + Updated TPJOSInfo: 116 | + Added detection of various Windows 10 and 11 builds and revisions released between 01 July and 02 November 2023: 117 | + Windows 10 21H2 public & release preview revisions. 118 | + Windows 10 22H2 public & release preview revisions. 119 | + Windows 11 21H2 public & release preview revisions. 120 | + Windows 11 22H2 public, release preview & beta channel revisions. 121 | + New Windows 11 22H3 public, release preview & beta channel revisions. 122 | + Windows 11 Dev & Canary channel builds. 123 | + Windows 11 Future Component Update Beta builds. 124 | + Removed support for detecting Windows Dev channel builds that expired in September 2023. 125 | + Updated some comments. 126 | + Minor formatting inconsistencies fixed in `CHANGELOG.md`. 127 | 128 | ## v5.23.0 of 01 July 2023 129 | 130 | + Updated TPJOSInfo to detect various Windows 10 and 11 builds and revisions released in June 2023: 131 | + Windows 10 21H2 public revisions. 132 | + Windows 10 22H2 public & release preview revisions. 133 | + Windows 11 21H2 public revisions. 134 | + Windows 11 22H2 public, release preview, beta channel revisions. 135 | + Added detection and reporting of Windows 11 22H2 "Moment 4". 136 | + Windows 11 Future Component Update Beta builds. 137 | + Windows 11 Dev & Canary channel builds. 138 | + Changed from version string 22H2 to 22H3 for Canary channel builds from build 25375. 139 | + Fixed TPJOSInfo errors re: 140 | + Some incorrect version strings used in various Windows 10 & 11 builds. 141 | + Some comments. 142 | 143 | ## v5.22.0 of 01 June 2023 144 | 145 | + Updated TPJOSInfo to detect various Windows 10 and 11 builds and revisions released in May 2023: 146 | + Final release of Windows 10 20H2. 147 | + Windows 11 build 22624 becomes "Windows 11 May 23 Component Update". 148 | + New Windows 11 build 22631 "Windows 11 Future Component Update". 149 | + Windows 11 22H2 public, release preview channel & beta channel revisions. 150 | + Windows 11 21H2 public & release preview channel revisions. 151 | + Added detection and reporting of Windows 11 22H2 "Moment" releases 1, 2 and 3. 152 | + Removed detection of expired Win 10 versions 1507, 1511 and 1607 preview builds. 153 | + Update comments to TPJOSInfo comment with new references. 154 | 155 | ## v5.21.1 of 02 May 2023 156 | 157 | + Fixed bug in TPJOSInfo where one of the build numbers used to detect Windows 11 Canary channel builds was wrong. 158 | 159 | ## v5.21.0 of 01 May 2023 160 | 161 | + Updated TPJOSInfo to detect various Windows builds and revisions released between 1 April and 30th April 2023, including: 162 | + Windows 11 22H2 public, release preview channel & beta channel revisions 163 | + Windows 11 21H2 public & release preview channel revisions 164 | + Windows 11 Future component update channel revisions 165 | + Windows 11 Dev channel builds 166 | + Windows 11 Canary channel builds 167 | + Windows 10 22H2 public & release preview channel revisions 168 | + Windows 10 21H2 public revisions 169 | + Some rename refactoring 170 | + Corrected and improved comments 171 | 172 | ## v5.20.0 of 01 April 2023 173 | 174 | + Updated TPJOSInfo to detect various Windows 10 and 11 builds released between 1 January and 31st March 2023, including: 175 | + public patches 176 | + release previews 177 | + Dev and Canary channel preview builds 178 | 179 | ## v5.19.0 of 01 January 2023 180 | 181 | + Updated TPJOSInfo OS detection: 182 | + Updated Windows 10 21H1, 21H2 & 22H2 and Windows 11 21H2 & 22H2 with pre-release & public builds released in December 2022. 183 | + Added detection of preview builds for Windows 10 Version 1507 through to Version 20H2. 184 | + Removed detection of expired Windows 10 & Windows 11 builds in Fast Ring and Dev channels. 185 | + Generally improved accuracy in detection of Windows 10 & 11 release & preview builds, reducing liklihood of false positives for unknown releases. 186 | + Changed to report certain v6.4 builds as being Windows 10 Version 1507 pre-releases. Reported OS for such builds is now Windows 10. 187 | + Added PROCESSOR_ARCHITECTURE_ARM64 constant. 188 | + Added some PRODUCT_* constants defined by Microsoft but missing from `PJSysInfo.pas`. 189 | + Updated and corrected product descriptions so there is a decription for each PRODUCT_* constant. 190 | + Fixed problem, starting from Windows 10 21H1, where some un-released preview builds were being reported as public releases. 191 | + Updated and tidied commenting in `PJSysInfo.pas`, including: 192 | + Added back URLs of some sources that were removed in a previous release. 193 | + Added tables providing information about end of life for Windows Vista to Windows 11 and all Windows Server releases. 194 | 195 | ## v5.18.0 of 01 December 2022 196 | 197 | + Updated TPJOSInfo to detect various builds of Windows 11 Version 22H2 that were released, either to the public or on the dev and release preview channels, in November 2022. 198 | 199 | ## v5.17.0 of 01 November 2022 200 | 201 | + Updated TPJOSInfo OS detection re: 202 | + Public release of Windows 10 Version 22H2 203 | + Win 10 & 11 Beta, release preview & dev channel builds from 1-31 October 2022. 204 | + Update change log for release 5.16.0 205 | 206 | ## v5.16.0 of 01 October 2022 207 | 208 | + Updated TPJOSInfo OS detection re: 209 | + Public release of Windows 11 Version 22H2. 210 | + Windows 11 Beta & release preview channel builds in from 2-30 Sepetember 2022. 211 | + Added build & revision numbers to text reported for Windows 10 Version 22H2 release previews. 212 | + Add `.gitignore` file. 213 | + Updated documentation: 214 | + Updated `README.md` "Effect of changes to the Windows API" sub-section. 215 | + Fix errors & update `Acknowledgements.md`. 216 | 217 | ## v5.15.0 of 02 September 2022 218 | 219 | + Updated TPJOSInfo detection of Win 11 Dev builds, 22H2 beta & release channel and alternative 22H2 beta channel builds to include all those released in August 2022 and on 1st September 2022. 220 | 221 | ## v5.14.0 of 01 August 2022 222 | 223 | + Updates to TPJOSInfo: 224 | + Added detection of Win 10 22H2 release preview build. 225 | + Added detection of alternative Win 11 22H2 beta build. 226 | + Added detection of Win 11 Dev channel and 22H2 revisions released in July 2022 227 | + Revised descriptions of Win 11 21H2 and 22H2 dev, beta and release 228 | preview revisions. 229 | + Updated URLs referenced in comments, removing broken URLs. 230 | 231 | ## v5.13.0 of 01 July 2022 232 | 233 | + Updates to TPJOSInfo: 234 | + Added support for detecting Windows 11 Dev channel and 22H2 Beta & Release Preview builds released in June 2022. 235 | + Improved reporting of unrecognised Windows 11 21H2 and 22H2 builds. 236 | + Fixed _**serious bug**_ in detection of known Windows 11 21H2 builds. 237 | + Fixed bug in detecting various OSs that report v10.0 (i.e. Windows 10 & 11 along with Windows Server products from Windows Server 2016 to Windows Server 2022). The bug was causing either Windows 10 or Windows 2016 server to be reported if build number detection failed, regardless of the OSs true build number. 238 | + Some refactoring. 239 | + Updated and clarified comments. 240 | 241 | ## v5.12.0 of 01 June 2022 242 | 243 | + Updates to TPJOSInfo: 244 | + Added support for detecting Dev and Beta releases of Windows 11 made during May 2022. 245 | + Refactored some OS detection code to reduce the amount of code used to test for various versions of OSs that report v10.0. 246 | + Documentation changes: 247 | + Replaced `/Docs/ReadMe.htm` with markdown formatted `/README.md`. Also expanded, brought up to date with recent changes, and fixed errors. 248 | + Replaced `/Docs/ChangeLog.txt` with markdown formatted `/CHANGELOG.md`. Also removed or struck out references to issues on Google Code. 249 | + Restored MPL v2 license file. 250 | + Updated documentation URL in the documentation shortcut file to a redirection URL on `delphidabbler.com`. 251 | + Deleted redundant `/Docs/Using RtlGetVersion.txt` file. 252 | + Fix some errors and omissions in this change log. 253 | + Revised `Release.bat`: 254 | + to take a version number as parameter to use in the release file name 255 | + to use the correct file in the release, following renaming. 256 | + re change from SVN Git 257 | + to permit `Zip.exe` to be called with no directory name when on the path. 258 | 259 | ## v5.11.0 of 01 May 2022 260 | 261 | + Fixed compilation bug that was preventing compilation with older versions of Delphi, probably those before Delphi XE7. Replaced all constant dynamic array declarations with initialised constant fixed size arrays. 262 | + Updates to TPJOSInfo: 263 | + Adds detection of Windows 11 Dev & Beta channel builds released since v5.10.0. 264 | + Refactored detection of Windows 2019 Server Insider Preview builds. 265 | 266 | ## v5.10.0 of 04 April 2022 267 | 268 | + Updates to TPJOSInfo: 269 | + Adds detection of recent Windows 11 Dev Channel releases. 270 | + Removes detection of build 22395 as Windows 10 22H2 preview build - available documentation does not support this. 271 | + Revised how Windows 11 Dev Channel builds are processed and reported, in line with newly found documentation. 272 | + Added detection of Windows 10 Fast Ring and Dev Channel releases. 273 | + Added detection of Windows 10 21H1 beta and 21H2 preview builds. 274 | 275 | ## v5.9.0 of 02 February 2022 276 | 277 | + Updates to TPJOSInfo: 278 | + Fixed mis-named Windows 2019 Server versions that should report as "Windows Server". Added new TPJOSProduct.osWinServer value and ammended code to detect and report the new "Windows Server" product type. 279 | + Added support for detecting Windows 10 version 22H1 preview builds. 280 | + Changed Windows 11 RSPRERELESE build 22509 to report "Windows 11 Insider Preview" instead of "Windows 11 Version 21H2". 281 | + Updated demo programs to be able to report osWinServer product type added to TPJOSInfo at this release. 282 | + Removed MPL2 license file. 283 | 284 | ## v5.8.0 of 01 January 2022 285 | 286 | + Fixed bug that was failing to detect KB updates to Windows 11 as valid production Windows 11 OS builds. 287 | + Added support for detecting newly released Windows 11 pre-release builds. 288 | + Some refactoring of OS build number detection code. 289 | 290 | ## v5.7.1 of 27 November 2021 291 | 292 | + Updated internal code following official release of Windows 10 21H2. No change to functionality from user's perspective. 293 | + Fixed a minor bug in Windows 11 detection code that is unlikely to have had any adverse effect. 294 | + Some refactoring. 295 | + General source code tidying. 296 | 297 | ## v5.7.0 of 05 October 2021 298 | 299 | + Updated TPJOSInfo to detect 1st release of Windows 11 (i.e. Windows 11 Version 21H2). 300 | 301 | ## v5.6.2 of 14 September 2021 302 | 303 | + Replaced non-ANSI dash characters with ASCII "-" characters to prevent possible problems compiling on old ANSI versions of Delphi. ~~Fixes issue #41~~ 304 | 305 | ## v5.6.1 of 12 September 2021 306 | 307 | + Made following methods inline, where supported: TPJOSInfo.IsWin9x, TPJOSInfo.IsWinNT, TPJOSInfo.IsWin32s, TPJOSInfo.ServicePackMajor, TPJOSInfo.ServicePackMinor & TPJComputerInfo.Is64Bit. Did not make any methods inline that would require extra units in uses clause of interface section of including units. 308 | + Documentation updates: 309 | + Fixed bug ~~#39~~ "Change log not updated for sysinfo v5.6" by adding the required release information. 310 | + Removed acknowledgements from PJSysUtils.pas header comments into a new Docs/Acknowledgements.md document. 311 | + Added new "Acknowledgements" section to `Docs/ReadMe.htm` that links to Acknowledgements.md on SourceForge. 312 | 313 | ## v5.6.0 of 12 September 2021 314 | 315 | + Add detection of following Windows & Windows Server versions: 316 | + Windows 10 Version 21H1 317 | + Windows 10 Version 21H2 (provisional build number: due late 2021) 318 | + DEV, Insider preview and beta versions of Windows 11 319 | + Windows 2018 Server Versions 2004 and 20H2 320 | + Windows 2022 Server Version 21H2 321 | + Add new code to get OS' revision number, accessible via: 322 | + New TPJOSInfo.RevisionNumber method 323 | + New Win32RevisionNumber global variable 324 | + Modify format of TPJOSInfo.Description when returning info about Win 2000 and later 325 | + Update list of web pages used to source build numbers of various Windows versions 326 | + Update VCL and FMX demo programs re support for detecting Windows 11 & Windows Server 2022 and to display result of calling new TPJOSInfo.RevisionNumber method and Win32RevisionNumber global variable. 327 | 328 | ## v5.5.0 of 31 October 2020 329 | 330 | + Updated to detect Windows 10 version 20H2, October 2020 update. 331 | 332 | ## v5.4.0 of 19 March 2020 333 | 334 | + Updated to detect Windows 10 updates from RS2 (version 1703) to 20H2 (version 2004) and added "marketing names" for updates from TH2 (version 1511) to 19H2 (version 1909) 335 | + Updated to detect 1st public release and all updates of Windows 2016 Server (i.e. up to version 1803) 336 | + Added detection of all Windows 2019 Server previews, 1st public release and all updates up to version 1909. 337 | + Added new TPJComputerInfo.ProcessorSpeedMHz method to return processor speed in MHz. 338 | + Updated demo programs re support for detecting Windows 2019 Server and to display result of new TPJComputerInfo.ProcessorSpeedMHz method. 339 | + Minor update to content and style of read-me file. 340 | 341 | ## v5.3.0 of 12 September 2016 342 | 343 | + Added support for detecting Windows 10 RS1 update - "Version 1607". 344 | + Renamed name of Windows 10 TH2 update from "November Update" to MSs new name - "Version 1511". 345 | + Added support for detecting Windows 2016 Server technical previews 1 to 5. 346 | + Revised TPJOSInfo.Description to include information from ServicePackEx method instead of ServicePack. 347 | + Minor update to read-me file. 348 | 349 | ## v5.2.0 of 30 November 2015 350 | 351 | + Added support for detecting build number of Windows 10 TH2 "November Update". 352 | + Added new TPJOSInfo.ServicePackEx method that reports any OS service packs present just like TPJOSInfo.ServicePack but also returns the name of any significant, detectable, update that does not declare itself as a service pack. This method was added to enable Windows 10 TH2 "November Update" to be reported since it does not report itself as a service pack. 353 | + Changed behaviour of the TPJOSInfo.BuildNumber method. When not using the GetVersionEx API the code tries to deduce the build number from other information. If this fails BuildNumber now returns 0 instead of attempting to read the build number from the registry. The registry was found to be returning incorrect build numbers. 354 | + Updated read-me file re changes. 355 | 356 | ## v5.1.0 of 11 September 2015 357 | 358 | + Added support for detecting Windows 10 for suitably manifested host applications. 359 | + Added new TPJOSInfo.IsReallyWindows10OrGreater method. 360 | + Changed so that Windows 8, in addition to Windows 8.1 and now Windows 10 can't be "spoofed". This was required so that Windows 8 will be reported when an un-manifested application is running on Windows 10, per Microsoft documentation. This is a breaking change from release 5.0.x. 361 | + Updated demo programs re support for detecting Windows 10 and to display result of new TPJOSInfo.IsReallyWindows10OrGreater method. Also added Windows 10 compatible manifest to each demo's resources. 362 | + Updated documentation re changes. 363 | + Updated URL of documentation in Documentation.URL shortcut file to reference `delphidabbler/ddab-lib-docs` repository. 364 | 365 | ## v5.0.2 of 30 October 2014 366 | 367 | + Fixed issue ~~#31~~ "PJSysInfo v5.0.1 does not work on earlier OSs" where TPJOSInfo was causing an access violation when run on Windows 98. 368 | + Fixed issue ~~#33~~ "IsServer and IsWindowsServer return True on Windows 98". 369 | 370 | ## v5.0.1 of 04 April 2014 371 | 372 | + Fixed issue ~~#29~~ "Out of range error" that occurred when using Windows 8.1 or Windows Server 2012 R2. 373 | + Added support for DEBUG symbol to force range checking to be on for debugging purposes. 374 | + Minor changes to documentation. 375 | 376 | ## v5.0.0 of 27 February 2014 377 | 378 | + Changed how operating system information is obtained and reported when running on Windows 8.1 (and later) in order to conform to API changes introduced by Microsoft in Windows 8.1. As a consequence when running on Windows 8.1 and later OS information for the installed OS will always be reported regardless of whether the host program is running in compatibility. On Windows 8 and earlier running in a compatibility mode will continue to cause OS information to be "spoofed" to reflect the emulated OS. 379 | + New compile option to help debug the Windows 8.1 method of OS information when using any OS back to Windows Vista. 380 | + Added new TPJOSInfo.CanSpoof method that indicates if compatibility mode will affect (spoof) reported OS information on the current operating system. 381 | + Windows 8.1 and Windows 2012 Server R2 are now detected and reported. 382 | + Windows XP Home Edition is now detected correctly. 383 | + Numerous new methods added to TPJOSInfo that can detect if the current OS is greater than or equal to a given OS. These methods are not affected by compatibility mode regardless of the compile option used. There is one method for every OS version and service pack from Windows 2000 onwards. 384 | + New TPJOSInfo.IsWindowsServer method that detects if the OS is a server in a manner not affected by compatibility mode for Windows 2000 and later. 385 | + New TPJOSInfo.InstallationDate method that returns the date the OS is installed. 386 | + New global variables added that are analogues of the SysUtils Win32*** variables but that are not affected by compatibility mode when run on Windows 8.1 or later. 387 | + New constants relating to obtaining version information not defined by all supported versions of Delphi have been added to the unit's interface section. 388 | + Updated demos: 389 | + Both VCL and FireMonkey 2 demos revised to display output of all new TPJOSInfo methods and new global variables. 390 | + VCL demo no longer scrolls when displaying lists of information that exceed window height. 391 | + Delphi 3 is no longer supported by the unit. 392 | + Updated documentation. 393 | 394 | ## v4.0.3 of 11 January 2014 395 | 396 | + Fixed problem with compiler directives in System Information Unit that was causing compilation to fail on Delphi XE5. 397 | + Minor documentation tweaks and corrections. 398 | 399 | ## v4.0.2 of 29 October 2013 400 | 401 | + Fixed potential registry access bug that may appear on Windows 2000 and earlier. ~~See comment #1 of issue #14.~~ 402 | 403 | ## v4.0.1 of 28 January 2013 404 | 405 | + Fixed bug in TPJOSInfo.RegisteredOrganisation ~~(issue #23)~~ 406 | 407 | ## v4.0.0 of 20 January 2013 408 | 409 | + `PJSysInfo.pas` is now compatible with Delphi 32 and 64 bit compilers and will compile with both VCL and FireMonkey 2 frameworks on Windows. 410 | + Added numerous new methods: 411 | + TPJComputerInfo: "IsAdmin", "IsUACActive", "BiosVendor", "ProcessorIdentifier", "ProcessorName", "SystemManufacturer" & "SystemProductName". 412 | + TPJSystemFolders: "ProgramFilesX86", "ProgramFilesRedirect", "CommonFilesX86" & "CommonFilesRedirect". 413 | + TPJOSInfo: "RegisteredOrganisation" & "RegisteredOwner". 414 | + All previously deprecated code removed, i.e.: 415 | + TPJSysInfo component and associated glyph file `PJSysInfo.dcr`. 416 | + All SIGetXXXX functions. 417 | + Used unit names are now qualified with namespace name on Delphi XE2 and later. 418 | + Changed original SysInfoDemo VCL project: 419 | + Default window font changed. 420 | + Form is no longer scaled. 421 | + Displayed text no longer word-wraps. 422 | + Added example output for all new methods. 423 | + Added manifest to resources to request themed controls and set elevation level. 424 | + New project configuration files with option to compile for 32 bit or 64 Windows targets on Delphi XE2 and later. 425 | + Added new FireMonkey 2 demo project with same basic functionality as revised SysInfoDemo project that can also be compiled for either 32 bit or 64 bit Windows targets. 426 | + Some refactoring. 427 | + WinHelp file removed. 428 | + Revised documentation and changed link to online help. 429 | + Demos placed in public domain. 430 | 431 | ## v3.4.0 of 24 October 2012 432 | 433 | + Modified TPJOSInfo to detect Windows 8 and Windows 2012 Server. 434 | + Added new PRODUCT_* constants and descriptions. 435 | + Updated demo to display newly added OS versions. 436 | + Changed license to Mozilla Public License v2.0 437 | + Updated help file re addition of Windows 8 / Windows 20012 Server and re change of license. 438 | + Updated documentation. 439 | 440 | ## v3.3.1 of 07 April 2010 441 | 442 | + Fixed bug ~~(issue #14)~~ to correctly read from registry on Windows 64 systems. NOTE: This bug may persist when compiled with old Delphis (pre Delphi 6). 443 | + Corrected buffer sizes used when TPJComputerInfo's ComputerName and UserName methods access Windows API functions. 444 | 445 | ## v3.3.0 of 31 December 2009 446 | 447 | + Added new TPJOSInfo.IsRemoteSession method to check if the executable is running under Windows Terminal Server as a remote session. 448 | + Updated help file accordingly. 449 | 450 | ## v3.2.2 of 16 December 2009 451 | 452 | + Fixed bug ~~(issue #1)~~ which prevented the unit from compiling with Delphi 5. 453 | 454 | ## v3.2.1 of 14 November 2009 455 | 456 | + Prevented warnings on Delphi 4 when compiling without deprecated components. 457 | + Updated documentation. 458 | 459 | ## v3.2.0 of 27 September 2009 460 | 461 | + Added some further PRODUCT_* constants that are new for Windows 7 / 2008 Server R2. 462 | + Changed character set handling to take account of Unicode and non-Unicode compilers. 463 | + Unit, but not demo, can now be compiled on Delphi 3. 464 | + Removed compiler warnings in Delphi 7. 465 | + All exceptions raised are now of type EPJsysInfo. 466 | + Updated documentation. 467 | 468 | ## v3.1.0 of 13 April 2009 469 | 470 | + Updated help file re revised static classes. 471 | + Revised demo program by adding output for new methods. 472 | + Added further PROCESSOR_ARCHITECTURE_XXX, PROCESSOR_XXX and PRODUCT_XXX constants. 473 | + Made default OS data structures use Unicode versions when UNICODE is defined by compiler. 474 | + Changed to use GetNativeSystemInfo API function to get processor architecture if possible. 475 | + Modified TPJOSInfo to detect Windows 7 and Windows 2008 Server R2. Also changed a few OS and product descriptions. 476 | + Modified TPJOSInfo.Edition to add 64bit qualification to OS edition information for OSs running on 64 bit systems and using GetProductInfo API. 477 | + Added BootMode and IsNetworkPresent methods to TPJComputerInfo. 478 | + Added TPJSystemFolders.SystemWow64 method. 479 | + Product name of unknown later Windows version now contains major and minor version numbers. 480 | 481 | ## v3.0.0 of 15 April 2008 482 | 483 | + Added support for GetProductInfo API (Vista) 484 | + Added support for Windows 2008 server and 2003 server R2. 485 | + Rewrote code that gets OS edition. 486 | + Added further VER_SUITE_ flags. 487 | + Added new PRODUCT_XXX and PROCESSOR_XXX flags. 488 | + Added new SM_STARTER and SM_SERVER2 constants. 489 | + Added Unicode version of OSVERSIONINFOEX and expanded number of types referring to ANSI and Unicode versions of these structures. 490 | + Added new methods to TPJOSInfo class. 491 | + Added new processor related methods to TPJComputerInfo. 492 | + Added new Win32XXX global variables relating to availability and value of product information. 493 | + Deprecated TPJSysInfo component and SIGetXXX are now compiled only if a special symbol is defined. By default they are not compiled and the component is not registered. 494 | + Updated help file re revised static class and removed topics for deprecated component and functions. 495 | + Revised demo program: 496 | + Added output for new methods. 497 | + Removed demo of deprecated code. 498 | 499 | ## v2.1.0 of 15 October 2006 500 | 501 | + Added new TPJComputerInfo.MACAddress method that gets the MAC address of the first available network card. 502 | 503 | ## v2.0.1 of 07 January 2006 504 | 505 | + Fixed bug in TPJOSInfo.ProductName method when running on Windows 2003. 506 | 507 | ## v2.0.0 of 13 November 2005 508 | 509 | + Added new static classes that duplicate and extend the features of the TPJSysInfo component: 510 | + TPJComputerInfo: provides information about the host computer; 511 | + TPJSystemFolders: gets paths to system folders; 512 | + TPJOSInfo: provides operating system information. 513 | + Added new features to the TOSInfo classes: 514 | + getting Windows product ID; 515 | + detection of Windows Vista, XP Media Edition and XP Tablet Edition; 516 | + detection of WOW64 sub-system; 517 | + further operating system detection features. 518 | + Added new global Win32* variables to provide extended operating system version information in style of variables from SysUtils unit. 519 | + Re-implemented TPJSysInfo and SIGet* functions in terms of new static classes. 520 | + Flagged TPJSysInfo and the SIGet* functions as deprecated. New static classes should now be used instead. 521 | + Made TOSVersionInfoEx type and VER_NT_* and VER_SUITE_* constants public. 522 | + Updated help file. 523 | + Added A-link keywords file for integration into Delphi 6/7 help systems. 524 | + Updated demo program re new features. 525 | 526 | ## v1.2.0 of 30 June 2003 527 | 528 | + Updated palette name to "DelphiDabbler" from "PJ Stuff". 529 | + Added support for Windows 2003 server to OS detection functions. 530 | + Removed requirement for Registry unit by accessing registry via Windows API where required. 531 | + Made TOSVersionInfoEx record definition into packed record. 532 | + GetOSProduct, GetOSProductType & GetOSServicePack updated according to latest example on MSDN. 533 | + Used resource strings for exception messages. 534 | + Updated help file. 535 | + Added new demo application. 536 | 537 | ## v1.1.0 of 25 November 2001 538 | 539 | + Added functions and component properties to retrieve Program Files and Common Files folders. 540 | 541 | ## v1.0.0 of 10 November 2001 542 | 543 | + Original version. 544 | -------------------------------------------------------------------------------- /Demos/FMX/FMXDemo.dpr: -------------------------------------------------------------------------------- 1 | { 2 | * Project file for System Information Unit FireMonkey demo program. 3 | * 4 | * Any copyright in this file is dedicated to the Public Domain. 5 | * http://creativecommons.org/publicdomain/zero/1.0/ 6 | } 7 | 8 | 9 | program FMXDemo; 10 | 11 | uses 12 | FMX.Forms, 13 | FmFMXDemo in 'FmFMXDemo.pas' {Form1}, 14 | PJSysInfo in '..\..\PJSysInfo.pas'; 15 | 16 | {$R 'MainIcon.res'} 17 | {$R 'Manifest.res'} 18 | 19 | begin 20 | Application.Initialize; 21 | Application.CreateForm(TForm1, Form1); 22 | Application.Run; 23 | end. 24 | -------------------------------------------------------------------------------- /Demos/FMX/FMXDemo.dproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | {DB9989AF-DE1C-4838-AD37-C67ED13D00EF} 4 | 20.2 5 | FMX 6 | FMXDemo.dpr 7 | True 8 | Base 9 | Win32 10 | 3 11 | Application 12 | FMXDemo 13 | 14 | 15 | true 16 | 17 | 18 | true 19 | Base 20 | true 21 | 22 | 23 | true 24 | Base 25 | true 26 | 27 | 28 | true 29 | Base 30 | true 31 | 32 | 33 | true 34 | Base 35 | true 36 | 37 | 38 | true 39 | Base 40 | true 41 | 42 | 43 | false 44 | 0 45 | Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;System;Xml;Data;Datasnap;Web;Soap;Winapi;System.Win;$(DCC_Namespace) 46 | 2057 47 | $(BDS)\bin\default_app.manifest 48 | CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments= 49 | FMXDemo_Icon.ico 50 | .\$(Platform) 51 | .\$(Platform) 52 | false 53 | false 54 | false 55 | false 56 | false 57 | FMXDemo 58 | $(BDS)\bin\delphi_PROJECTICNS.icns 59 | 60 | 61 | $(BDS)\bin\Artwork\Android\FM_LauncherIcon_36x36.png 62 | $(BDS)\bin\Artwork\Android\FM_LauncherIcon_48x48.png 63 | $(BDS)\bin\Artwork\Android\FM_LauncherIcon_72x72.png 64 | $(BDS)\bin\Artwork\Android\FM_LauncherIcon_96x96.png 65 | $(BDS)\bin\Artwork\Android\FM_LauncherIcon_144x144.png 66 | $(BDS)\bin\Artwork\Android\FM_SplashImage_426x320.png 67 | $(BDS)\bin\Artwork\Android\FM_SplashImage_470x320.png 68 | $(BDS)\bin\Artwork\Android\FM_SplashImage_640x480.png 69 | $(BDS)\bin\Artwork\Android\FM_SplashImage_960x720.png 70 | true 71 | true 72 | true 73 | true 74 | true 75 | true 76 | true 77 | true 78 | true 79 | true 80 | $(BDS)\bin\Artwork\Android\FM_NotificationIcon_24x24.png 81 | $(BDS)\bin\Artwork\Android\FM_NotificationIcon_36x36.png 82 | $(BDS)\bin\Artwork\Android\FM_NotificationIcon_48x48.png 83 | $(BDS)\bin\Artwork\Android\FM_NotificationIcon_72x72.png 84 | $(BDS)\bin\Artwork\Android\FM_NotificationIcon_96x96.png 85 | 86 | 87 | $(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_120x120.png 88 | $(BDS)\bin\Artwork\iOS\iPhone\FM_SpotlightSearchIcon_80x80.png 89 | $(BDS)\bin\Artwork\iOS\iPhone\FM_NotificationIcon_40x40.png 90 | $(BDS)\bin\Artwork\iOS\iPhone\FM_NotificationIcon_60x60.png 91 | $(BDS)\bin\Artwork\iOS\iPad\FM_SpotlightSearchIcon_80x80.png 92 | $(BDS)\bin\Artwork\iOS\iPad\FM_NotificationIcon_40x40.png 93 | $(BDS)\bin\Artwork\iOS\iPad\FM_ApplicationIcon_152x152.png 94 | $(BDS)\bin\Artwork\iOS\iPhone\FM_SettingIcon_87x87.png 95 | $(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_180x180.png 96 | $(BDS)\bin\Artwork\iOS\iPhone\FM_SpotlightSearchIcon_120x120.png 97 | $(BDS)\bin\Artwork\iOS\iPad\FM_ApplicationIcon_167x167.png 98 | 99 | 100 | $(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_120x120.png 101 | $(BDS)\bin\Artwork\iOS\iPhone\FM_SpotlightSearchIcon_80x80.png 102 | $(BDS)\bin\Artwork\iOS\iPhone\FM_NotificationIcon_40x40.png 103 | $(BDS)\bin\Artwork\iOS\iPhone\FM_NotificationIcon_60x60.png 104 | $(BDS)\bin\Artwork\iOS\iPad\FM_SpotlightSearchIcon_80x80.png 105 | $(BDS)\bin\Artwork\iOS\iPad\FM_NotificationIcon_40x40.png 106 | $(BDS)\bin\Artwork\iOS\iPad\FM_ApplicationIcon_152x152.png 107 | $(BDS)\bin\Artwork\iOS\iPhone\FM_SettingIcon_87x87.png 108 | $(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_180x180.png 109 | $(BDS)\bin\Artwork\iOS\iPhone\FM_SpotlightSearchIcon_120x120.png 110 | $(BDS)\bin\Artwork\iOS\iPad\FM_ApplicationIcon_167x167.png 111 | $(BDS)\bin\Artwork\iOS\iPhone\FM_LaunchImage_2x.png 112 | $(BDS)\bin\Artwork\iOS\iPhone\FM_LaunchImageDark_2x.png 113 | $(BDS)\bin\Artwork\iOS\iPhone\FM_LaunchImage_3x.png 114 | $(BDS)\bin\Artwork\iOS\iPhone\FM_LaunchImageDark_3x.png 115 | $(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImage_2x.png 116 | $(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImageDark_2x.png 117 | 10.0 118 | 119 | 120 | DDabLib32;bindcompfmx;DBXSqliteDriver;vcldbx;fmx;rtl;dbrtl;DbxClientDriver;IndySystem;TeeDB;bindcomp;inetdb;vclib;inetdbbde;DBXInterBaseDriver;Tee;DataSnapCommon;xmlrtl;svnui;ibxpress;DbxCommonDriver;vclimg;IndyProtocols;dbxcds;DBXMySQLDriver;MetropolisUILiveTile;vclactnband;bindengine;vcldb;soaprtl;bindcompdbx;vcldsnap;bindcompvcl;FMXTee;TeeUI;vclie;vcltouch;websnap;CustomIPTransport;vclribbon;VclSmp;dsnap;IndyIPServer;Intraweb;fmxase;vcl;IndyCore;IndyIPCommon;CloudService;CodeSiteExpressPkg;dsnapcon;FmxTeeUI;inet;fmxobj;vclx;inetdbxpress;webdsnap;svn;fmxdae;bdertl;dbexpress;adortl;IndyIPClient;$(DCC_UsePackage) 121 | 1033 122 | $(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_44.png 123 | $(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_150.png 124 | Debug 125 | 126 | 127 | bindcompfmx;DBXSqliteDriver;fmx;rtl;dbrtl;DbxClientDriver;IndySystem;bindcomp;inetdb;DBXInterBaseDriver;DataSnapCommon;xmlrtl;DbxCommonDriver;vclimg;IndyProtocols;dbxcds;DBXMySQLDriver;vclactnband;bindengine;vcldb;soaprtl;bindcompdbx;vcldsnap;bindcompvcl;vclie;vcltouch;websnap;CustomIPTransport;VclSmp;dsnap;IndyIPServer;fmxase;vcl;IndyCore;IndyIPCommon;dsnapcon;inet;fmxobj;vclx;inetdbxpress;webdsnap;fmxdae;dbexpress;IndyIPClient;$(DCC_UsePackage) 128 | 1033 129 | $(BDS)\bin\default_app.manifest 130 | $(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_44.png 131 | $(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_150.png 132 | Debug 133 | 134 | 135 | 136 | MainSource 137 | 138 | 139 |
Form1
140 | fmx 141 |
142 | 143 | 144 | Base 145 | 146 |
147 | 148 | Delphi.Personality.12 149 | 150 | 151 | 152 | 153 | False 154 | False 155 | 1 156 | 0 157 | 0 158 | 0 159 | False 160 | False 161 | False 162 | False 163 | False 164 | 2057 165 | 1252 166 | 167 | 168 | 169 | 170 | 1.0.0.0 171 | 172 | 173 | 174 | 175 | 176 | 1.0.0.0 177 | 178 | 179 | 180 | 181 | 182 | 183 | 184 | 185 | 186 | 187 | 188 | FMXDemo.dpr 189 | 190 | 191 | Microsoft Office 2000 Sample Automation Server Wrapper Components 192 | Microsoft Office XP Sample Automation Server Wrapper Components 193 | 194 | 195 | 196 | 197 | 198 | true 199 | 200 | 201 | 202 | 203 | true 204 | 205 | 206 | 207 | 208 | true 209 | 210 | 211 | 212 | 213 | 1 214 | 215 | 216 | Contents\MacOS 217 | 1 218 | 219 | 220 | 0 221 | 222 | 223 | 224 | 225 | res\xml 226 | 1 227 | 228 | 229 | res\xml 230 | 1 231 | 232 | 233 | 234 | 235 | library\lib\armeabi 236 | 1 237 | 238 | 239 | library\lib\armeabi 240 | 1 241 | 242 | 243 | 244 | 245 | library\lib\armeabi-v7a 246 | 1 247 | 248 | 249 | 250 | 251 | library\lib\mips 252 | 1 253 | 254 | 255 | library\lib\mips 256 | 1 257 | 258 | 259 | 260 | 261 | library\lib\armeabi-v7a 262 | 1 263 | 264 | 265 | library\lib\arm64-v8a 266 | 1 267 | 268 | 269 | 270 | 271 | library\lib\armeabi-v7a 272 | 1 273 | 274 | 275 | 276 | 277 | res\drawable 278 | 1 279 | 280 | 281 | res\drawable 282 | 1 283 | 284 | 285 | 286 | 287 | res\drawable-anydpi-v21 288 | 1 289 | 290 | 291 | res\drawable-anydpi-v21 292 | 1 293 | 294 | 295 | 296 | 297 | res\values 298 | 1 299 | 300 | 301 | res\values 302 | 1 303 | 304 | 305 | 306 | 307 | res\values-v21 308 | 1 309 | 310 | 311 | res\values-v21 312 | 1 313 | 314 | 315 | 316 | 317 | res\values-v31 318 | 1 319 | 320 | 321 | res\values-v31 322 | 1 323 | 324 | 325 | 326 | 327 | res\drawable-anydpi-v26 328 | 1 329 | 330 | 331 | res\drawable-anydpi-v26 332 | 1 333 | 334 | 335 | 336 | 337 | res\drawable 338 | 1 339 | 340 | 341 | res\drawable 342 | 1 343 | 344 | 345 | 346 | 347 | res\drawable 348 | 1 349 | 350 | 351 | res\drawable 352 | 1 353 | 354 | 355 | 356 | 357 | res\drawable 358 | 1 359 | 360 | 361 | res\drawable 362 | 1 363 | 364 | 365 | 366 | 367 | res\drawable-anydpi-v33 368 | 1 369 | 370 | 371 | res\drawable-anydpi-v33 372 | 1 373 | 374 | 375 | 376 | 377 | res\values 378 | 1 379 | 380 | 381 | res\values 382 | 1 383 | 384 | 385 | 386 | 387 | res\values-night-v21 388 | 1 389 | 390 | 391 | res\values-night-v21 392 | 1 393 | 394 | 395 | 396 | 397 | res\drawable 398 | 1 399 | 400 | 401 | res\drawable 402 | 1 403 | 404 | 405 | 406 | 407 | res\drawable-xxhdpi 408 | 1 409 | 410 | 411 | res\drawable-xxhdpi 412 | 1 413 | 414 | 415 | 416 | 417 | res\drawable-xxxhdpi 418 | 1 419 | 420 | 421 | res\drawable-xxxhdpi 422 | 1 423 | 424 | 425 | 426 | 427 | res\drawable-ldpi 428 | 1 429 | 430 | 431 | res\drawable-ldpi 432 | 1 433 | 434 | 435 | 436 | 437 | res\drawable-mdpi 438 | 1 439 | 440 | 441 | res\drawable-mdpi 442 | 1 443 | 444 | 445 | 446 | 447 | res\drawable-hdpi 448 | 1 449 | 450 | 451 | res\drawable-hdpi 452 | 1 453 | 454 | 455 | 456 | 457 | res\drawable-xhdpi 458 | 1 459 | 460 | 461 | res\drawable-xhdpi 462 | 1 463 | 464 | 465 | 466 | 467 | res\drawable-mdpi 468 | 1 469 | 470 | 471 | res\drawable-mdpi 472 | 1 473 | 474 | 475 | 476 | 477 | res\drawable-hdpi 478 | 1 479 | 480 | 481 | res\drawable-hdpi 482 | 1 483 | 484 | 485 | 486 | 487 | res\drawable-xhdpi 488 | 1 489 | 490 | 491 | res\drawable-xhdpi 492 | 1 493 | 494 | 495 | 496 | 497 | res\drawable-xxhdpi 498 | 1 499 | 500 | 501 | res\drawable-xxhdpi 502 | 1 503 | 504 | 505 | 506 | 507 | res\drawable-xxxhdpi 508 | 1 509 | 510 | 511 | res\drawable-xxxhdpi 512 | 1 513 | 514 | 515 | 516 | 517 | res\drawable-small 518 | 1 519 | 520 | 521 | res\drawable-small 522 | 1 523 | 524 | 525 | 526 | 527 | res\drawable-normal 528 | 1 529 | 530 | 531 | res\drawable-normal 532 | 1 533 | 534 | 535 | 536 | 537 | res\drawable-large 538 | 1 539 | 540 | 541 | res\drawable-large 542 | 1 543 | 544 | 545 | 546 | 547 | res\drawable-xlarge 548 | 1 549 | 550 | 551 | res\drawable-xlarge 552 | 1 553 | 554 | 555 | 556 | 557 | res\values 558 | 1 559 | 560 | 561 | res\values 562 | 1 563 | 564 | 565 | 566 | 567 | res\drawable-anydpi-v24 568 | 1 569 | 570 | 571 | res\drawable-anydpi-v24 572 | 1 573 | 574 | 575 | 576 | 577 | res\drawable 578 | 1 579 | 580 | 581 | res\drawable 582 | 1 583 | 584 | 585 | 586 | 587 | res\drawable-night-anydpi-v21 588 | 1 589 | 590 | 591 | res\drawable-night-anydpi-v21 592 | 1 593 | 594 | 595 | 596 | 597 | res\drawable-anydpi-v31 598 | 1 599 | 600 | 601 | res\drawable-anydpi-v31 602 | 1 603 | 604 | 605 | 606 | 607 | res\drawable-night-anydpi-v31 608 | 1 609 | 610 | 611 | res\drawable-night-anydpi-v31 612 | 1 613 | 614 | 615 | 616 | 617 | 1 618 | 619 | 620 | Contents\MacOS 621 | 1 622 | 623 | 624 | 0 625 | 626 | 627 | 628 | 629 | Contents\MacOS 630 | 1 631 | .framework 632 | 633 | 634 | Contents\MacOS 635 | 1 636 | .framework 637 | 638 | 639 | Contents\MacOS 640 | 1 641 | .framework 642 | 643 | 644 | 0 645 | 646 | 647 | 648 | 649 | 1 650 | .dylib 651 | 652 | 653 | 1 654 | .dylib 655 | 656 | 657 | 1 658 | .dylib 659 | 660 | 661 | Contents\MacOS 662 | 1 663 | .dylib 664 | 665 | 666 | Contents\MacOS 667 | 1 668 | .dylib 669 | 670 | 671 | Contents\MacOS 672 | 1 673 | .dylib 674 | 675 | 676 | 0 677 | .dll;.bpl 678 | 679 | 680 | 681 | 682 | 1 683 | .dylib 684 | 685 | 686 | 1 687 | .dylib 688 | 689 | 690 | 1 691 | .dylib 692 | 693 | 694 | Contents\MacOS 695 | 1 696 | .dylib 697 | 698 | 699 | Contents\MacOS 700 | 1 701 | .dylib 702 | 703 | 704 | Contents\MacOS 705 | 1 706 | .dylib 707 | 708 | 709 | 0 710 | .bpl 711 | 712 | 713 | 714 | 715 | 0 716 | 717 | 718 | 0 719 | 720 | 721 | 0 722 | 723 | 724 | 0 725 | 726 | 727 | 0 728 | 729 | 730 | Contents\Resources\StartUp\ 731 | 0 732 | 733 | 734 | Contents\Resources\StartUp\ 735 | 0 736 | 737 | 738 | Contents\Resources\StartUp\ 739 | 0 740 | 741 | 742 | 0 743 | 744 | 745 | 746 | 747 | 1 748 | 749 | 750 | 1 751 | 752 | 753 | 754 | 755 | ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF 756 | 1 757 | 758 | 759 | ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF 760 | 1 761 | 762 | 763 | 764 | 765 | ..\ 766 | 1 767 | 768 | 769 | ..\ 770 | 1 771 | 772 | 773 | ..\ 774 | 1 775 | 776 | 777 | 778 | 779 | Contents 780 | 1 781 | 782 | 783 | Contents 784 | 1 785 | 786 | 787 | Contents 788 | 1 789 | 790 | 791 | 792 | 793 | Contents\Resources 794 | 1 795 | 796 | 797 | Contents\Resources 798 | 1 799 | 800 | 801 | Contents\Resources 802 | 1 803 | 804 | 805 | 806 | 807 | library\lib\armeabi-v7a 808 | 1 809 | 810 | 811 | library\lib\arm64-v8a 812 | 1 813 | 814 | 815 | 1 816 | 817 | 818 | 1 819 | 820 | 821 | 1 822 | 823 | 824 | 1 825 | 826 | 827 | Contents\MacOS 828 | 1 829 | 830 | 831 | Contents\MacOS 832 | 1 833 | 834 | 835 | Contents\MacOS 836 | 1 837 | 838 | 839 | 0 840 | 841 | 842 | 843 | 844 | library\lib\armeabi-v7a 845 | 1 846 | 847 | 848 | 849 | 850 | 1 851 | 852 | 853 | 1 854 | 855 | 856 | 1 857 | 858 | 859 | 860 | 861 | ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF 862 | 1 863 | 864 | 865 | ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF 866 | 1 867 | 868 | 869 | ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF 870 | 1 871 | 872 | 873 | 874 | 875 | ..\ 876 | 1 877 | 878 | 879 | ..\ 880 | 1 881 | 882 | 883 | ..\ 884 | 1 885 | 886 | 887 | 888 | 889 | 1 890 | 891 | 892 | 1 893 | 894 | 895 | 1 896 | 897 | 898 | 899 | 900 | ..\$(PROJECTNAME).launchscreen 901 | 64 902 | 903 | 904 | ..\$(PROJECTNAME).launchscreen 905 | 64 906 | 907 | 908 | 909 | 910 | 1 911 | 912 | 913 | 1 914 | 915 | 916 | 1 917 | 918 | 919 | 920 | 921 | Assets 922 | 1 923 | 924 | 925 | Assets 926 | 1 927 | 928 | 929 | 930 | 931 | Assets 932 | 1 933 | 934 | 935 | Assets 936 | 1 937 | 938 | 939 | 940 | 941 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 942 | 1 943 | 944 | 945 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 946 | 1 947 | 948 | 949 | 950 | 951 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 952 | 1 953 | 954 | 955 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 956 | 1 957 | 958 | 959 | 960 | 961 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 962 | 1 963 | 964 | 965 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 966 | 1 967 | 968 | 969 | 970 | 971 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 972 | 1 973 | 974 | 975 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 976 | 1 977 | 978 | 979 | 980 | 981 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 982 | 1 983 | 984 | 985 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 986 | 1 987 | 988 | 989 | 990 | 991 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 992 | 1 993 | 994 | 995 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 996 | 1 997 | 998 | 999 | 1000 | 1001 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1002 | 1 1003 | 1004 | 1005 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1006 | 1 1007 | 1008 | 1009 | 1010 | 1011 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1012 | 1 1013 | 1014 | 1015 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1016 | 1 1017 | 1018 | 1019 | 1020 | 1021 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1022 | 1 1023 | 1024 | 1025 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1026 | 1 1027 | 1028 | 1029 | 1030 | 1031 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1032 | 1 1033 | 1034 | 1035 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1036 | 1 1037 | 1038 | 1039 | 1040 | 1041 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 1042 | 1 1043 | 1044 | 1045 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 1046 | 1 1047 | 1048 | 1049 | 1050 | 1051 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 1052 | 1 1053 | 1054 | 1055 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 1056 | 1 1057 | 1058 | 1059 | 1060 | 1061 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 1062 | 1 1063 | 1064 | 1065 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 1066 | 1 1067 | 1068 | 1069 | 1070 | 1071 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 1072 | 1 1073 | 1074 | 1075 | ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset 1076 | 1 1077 | 1078 | 1079 | 1080 | 1081 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1082 | 1 1083 | 1084 | 1085 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1086 | 1 1087 | 1088 | 1089 | 1090 | 1091 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1092 | 1 1093 | 1094 | 1095 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1096 | 1 1097 | 1098 | 1099 | 1100 | 1101 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1102 | 1 1103 | 1104 | 1105 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1106 | 1 1107 | 1108 | 1109 | 1110 | 1111 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1112 | 1 1113 | 1114 | 1115 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1116 | 1 1117 | 1118 | 1119 | 1120 | 1121 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1122 | 1 1123 | 1124 | 1125 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1126 | 1 1127 | 1128 | 1129 | 1130 | 1131 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1132 | 1 1133 | 1134 | 1135 | ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset 1136 | 1 1137 | 1138 | 1139 | 1140 | 1141 | 1142 | 1143 | 1144 | 1145 | 1146 | 1147 | 1148 | 1149 | 1150 | 1151 | 1152 | 1153 | False 1154 | False 1155 | False 1156 | False 1157 | True 1158 | True 1159 | 1160 | 1161 | 12 1162 | 1163 | 1164 | 1165 | 1166 |
1167 | -------------------------------------------------------------------------------- /Demos/FMX/FMXDemo.manifest: -------------------------------------------------------------------------------- 1 |  2 | 3 | 8 | System Info Demo for FireMonkey by DelphiDabbler 9 | 10 | 11 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /Demos/FMX/FMXDemo_Icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ddablib/sysinfo/4a7e984fae868a09b16a7fe2c69fdc5a9876145d/Demos/FMX/FMXDemo_Icon.ico -------------------------------------------------------------------------------- /Demos/FMX/FmFMXDemo.fmx: -------------------------------------------------------------------------------- 1 | object Form1: TForm1 2 | Left = 0 3 | Top = 0 4 | Caption = 'Form1' 5 | ClientHeight = 508 6 | ClientWidth = 688 7 | FormFactor.Width = 1920 8 | FormFactor.Height = 1080 9 | FormFactor.Devices = [Desktop, iPhone, iPad] 10 | OnCreate = FormCreate 11 | DesignerMasterStyle = 0 12 | object Layout1: TLayout 13 | Align = Client 14 | Size.Width = 688.000000000000000000 15 | Size.Height = 508.000000000000000000 16 | Size.PlatformDefault = False 17 | TabOrder = 0 18 | object TabControl1: TTabControl 19 | Align = Client 20 | Padding.Left = 4.000000000000000000 21 | Padding.Top = 4.000000000000000000 22 | Padding.Right = 4.000000000000000000 23 | Padding.Bottom = 4.000000000000000000 24 | Margins.Left = 4.000000000000000000 25 | Margins.Top = 4.000000000000000000 26 | Margins.Right = 4.000000000000000000 27 | Margins.Bottom = 4.000000000000000000 28 | Size.Width = 680.000000000000000000 29 | Size.Height = 500.000000000000000000 30 | Size.PlatformDefault = False 31 | TabIndex = 4 32 | TabOrder = 0 33 | TabPosition = Top 34 | OnChange = TabControl1Change 35 | Sizes = ( 36 | 672s 37 | 466s 38 | 672s 39 | 466s 40 | 672s 41 | 466s 42 | 672s 43 | 466s 44 | 672s 45 | 466s) 46 | object tiComputerInfo: TTabItem 47 | CustomIcon = < 48 | item 49 | end> 50 | TextSettings.Trimming = None 51 | IsSelected = False 52 | Size.Width = 111.000000000000000000 53 | Size.Height = 26.000000000000000000 54 | Size.PlatformDefault = False 55 | StyleLookup = '' 56 | TabOrder = 0 57 | Text = 'TPJComputerInfo' 58 | ExplicitSize.cx = 50.000000000000000000 59 | ExplicitSize.cy = 50.000000000000000000 60 | object sgComputerInfo: TStringGrid 61 | Align = Client 62 | CanFocus = True 63 | ClipChildren = True 64 | Size.Width = 672.000000000000000000 65 | Size.Height = 466.000000000000000000 66 | Size.PlatformDefault = False 67 | TabOrder = 0 68 | RowHeight = 21.000000000000000000 69 | Options = [ColumnResize, ColumnMove, ColLines, RowLines, Tabs, Header, HeaderClick, AutoDisplacement] 70 | OnResized = sgResized 71 | Viewport.Width = 652.000000000000000000 72 | Viewport.Height = 441.000000000000000000 73 | object StringColumn1: TStringColumn 74 | Header = 'Method' 75 | HeaderSettings.TextSettings.WordWrap = False 76 | ReadOnly = True 77 | Size.Width = 240.000000000000000000 78 | end 79 | object StringColumn2: TStringColumn 80 | Header = 'Value' 81 | HeaderSettings.TextSettings.WordWrap = False 82 | ReadOnly = True 83 | Size.Width = 400.000000000000000000 84 | end 85 | end 86 | end 87 | object tiBiosInfo: TTabItem 88 | CustomIcon = < 89 | item 90 | end> 91 | TextSettings.Trimming = None 92 | IsSelected = False 93 | Size.Width = 79.000000000000000000 94 | Size.Height = 26.000000000000000000 95 | Size.PlatformDefault = False 96 | StyleLookup = '' 97 | TabOrder = 0 98 | Text = 'TPJBiosInfo' 99 | object sgBiosInfo: TStringGrid 100 | Align = Client 101 | CanFocus = True 102 | ClipChildren = True 103 | Size.Width = 672.000000000000000000 104 | Size.Height = 466.000000000000000000 105 | Size.PlatformDefault = False 106 | TabOrder = 0 107 | RowHeight = 21.000000000000000000 108 | Options = [ColumnResize, ColumnMove, ColLines, RowLines, Tabs, Header, HeaderClick, AutoDisplacement] 109 | OnResized = sgResized 110 | Viewport.Width = 652.000000000000000000 111 | Viewport.Height = 441.000000000000000000 112 | object StringColumn9: TStringColumn 113 | Header = 'Method' 114 | HeaderSettings.TextSettings.WordWrap = False 115 | ReadOnly = True 116 | Size.Width = 240.000000000000000000 117 | end 118 | object StringColumn10: TStringColumn 119 | Header = 'Value' 120 | HeaderSettings.TextSettings.WordWrap = False 121 | ReadOnly = True 122 | Size.Width = 400.000000000000000000 123 | end 124 | end 125 | end 126 | object tiSpecialFolders: TTabItem 127 | CustomIcon = < 128 | item 129 | end> 130 | TextSettings.Trimming = None 131 | IsSelected = False 132 | Size.Width = 113.000000000000000000 133 | Size.Height = 26.000000000000000000 134 | Size.PlatformDefault = False 135 | StyleLookup = '' 136 | TabOrder = 0 137 | Text = 'TPJSpecialFolders' 138 | ExplicitSize.cx = 50.000000000000000000 139 | ExplicitSize.cy = 50.000000000000000000 140 | object sgSpecialFolders: TStringGrid 141 | Align = Client 142 | CanFocus = True 143 | ClipChildren = True 144 | Size.Width = 672.000000000000000000 145 | Size.Height = 466.000000000000000000 146 | Size.PlatformDefault = False 147 | TabOrder = 0 148 | RowHeight = 21.000000000000000000 149 | Options = [ColumnResize, ColumnMove, ColLines, RowLines, Tabs, Header, HeaderClick, AutoDisplacement] 150 | OnResized = sgResized 151 | Viewport.Width = 652.000000000000000000 152 | Viewport.Height = 441.000000000000000000 153 | object StringColumn5: TStringColumn 154 | Header = 'Method' 155 | HeaderSettings.TextSettings.WordWrap = False 156 | ReadOnly = True 157 | Size.Width = 240.000000000000000000 158 | end 159 | object StringColumn6: TStringColumn 160 | Header = 'Value' 161 | HeaderSettings.TextSettings.WordWrap = False 162 | ReadOnly = True 163 | Size.Width = 400.000000000000000000 164 | end 165 | end 166 | end 167 | object tiOSInfo: TTabItem 168 | CustomIcon = < 169 | item 170 | end> 171 | TextSettings.Trimming = None 172 | IsSelected = False 173 | Size.Width = 73.000000000000000000 174 | Size.Height = 26.000000000000000000 175 | Size.PlatformDefault = False 176 | StyleLookup = '' 177 | TabOrder = 0 178 | Text = 'TPJOSInfo' 179 | ExplicitSize.cx = 50.000000000000000000 180 | ExplicitSize.cy = 50.000000000000000000 181 | object sgOSInfo: TStringGrid 182 | Align = Client 183 | CanFocus = True 184 | ClipChildren = True 185 | Size.Width = 672.000000000000000000 186 | Size.Height = 466.000000000000000000 187 | Size.PlatformDefault = False 188 | TabOrder = 0 189 | RowHeight = 21.000000000000000000 190 | Options = [ColumnResize, ColumnMove, ColLines, RowLines, Tabs, Header, HeaderClick, AutoDisplacement] 191 | OnResized = sgResized 192 | Viewport.Width = 652.000000000000000000 193 | Viewport.Height = 441.000000000000000000 194 | object StringColumn3: TStringColumn 195 | Header = 'Method' 196 | HeaderSettings.TextSettings.WordWrap = False 197 | ReadOnly = True 198 | Size.Width = 240.000000000000000000 199 | end 200 | object StringColumn4: TStringColumn 201 | Header = 'Value' 202 | HeaderSettings.TextSettings.WordWrap = False 203 | ReadOnly = True 204 | Size.Width = 400.000000000000000000 205 | end 206 | end 207 | end 208 | object tiWin32Globals: TTabItem 209 | CustomIcon = < 210 | item 211 | end> 212 | TextSettings.Trimming = None 213 | IsSelected = True 214 | Size.Width = 97.000000000000000000 215 | Size.Height = 26.000000000000000000 216 | Size.PlatformDefault = False 217 | StyleLookup = '' 218 | TabOrder = 0 219 | Text = 'Win32 Globals' 220 | ExplicitSize.cx = 50.000000000000000000 221 | ExplicitSize.cy = 50.000000000000000000 222 | object sgWin32Globals: TStringGrid 223 | Align = Client 224 | CanFocus = True 225 | ClipChildren = True 226 | Size.Width = 672.000000000000000000 227 | Size.Height = 466.000000000000000000 228 | Size.PlatformDefault = False 229 | TabOrder = 0 230 | RowHeight = 21.000000000000000000 231 | Options = [ColumnResize, ColumnMove, ColLines, RowLines, Tabs, Header, HeaderClick, AutoDisplacement] 232 | OnResized = sgResized 233 | Viewport.Width = 652.000000000000000000 234 | Viewport.Height = 441.000000000000000000 235 | object StringColumn7: TStringColumn 236 | Header = 'Method' 237 | HeaderSettings.TextSettings.WordWrap = False 238 | ReadOnly = True 239 | Size.Width = 240.000000000000000000 240 | end 241 | object StringColumn8: TStringColumn 242 | Header = 'Value' 243 | HeaderSettings.TextSettings.WordWrap = False 244 | ReadOnly = True 245 | Size.Width = 400.000000000000000000 246 | end 247 | end 248 | end 249 | end 250 | end 251 | end 252 | -------------------------------------------------------------------------------- /Demos/FMX/FmFMXDemo.pas: -------------------------------------------------------------------------------- 1 | { 2 | * Main form file for System Information Unit FireMonkey demo program. 3 | * 4 | * Any copyright in this file is dedicated to the Public Domain. 5 | * http://creativecommons.org/publicdomain/zero/1.0/ 6 | } 7 | 8 | 9 | unit FmFMXDemo; 10 | 11 | interface 12 | 13 | uses 14 | System.SysUtils, System.Types, System.UITypes, System.Rtti, System.Classes, 15 | System.Variants, FMX.Types, FMX.Controls, FMX.Forms, FMX.Dialogs, 16 | FMX.TabControl, FMX.Ani, FMX.Layouts, FMX.Memo, 17 | FMX.ListBox, FMX.TreeView, FMX.Grid, FMX.Grid.Style, 18 | FMX.Controls.Presentation, FMX.ScrollBox, 19 | 20 | PJSysInfo; 21 | 22 | type 23 | TForm1 = class(TForm) 24 | Layout1: TLayout; 25 | TabControl1: TTabControl; 26 | tiComputerInfo: TTabItem; 27 | tiSpecialFolders: TTabItem; 28 | tiOSInfo: TTabItem; 29 | tiWin32Globals: TTabItem; 30 | sgComputerInfo: TStringGrid; 31 | StringColumn1: TStringColumn; 32 | StringColumn2: TStringColumn; 33 | sgOSInfo: TStringGrid; 34 | StringColumn3: TStringColumn; 35 | StringColumn4: TStringColumn; 36 | sgSpecialFolders: TStringGrid; 37 | StringColumn5: TStringColumn; 38 | StringColumn6: TStringColumn; 39 | sgWin32Globals: TStringGrid; 40 | StringColumn7: TStringColumn; 41 | StringColumn8: TStringColumn; 42 | tiBiosInfo: TTabItem; 43 | sgBiosInfo: TStringGrid; 44 | StringColumn9: TStringColumn; 45 | StringColumn10: TStringColumn; 46 | procedure TabControl1Change(Sender: TObject); 47 | procedure FormCreate(Sender: TObject); 48 | procedure sgResized(Sender: TObject); 49 | private 50 | procedure DisplayItem(const SG: TStringGrid; const Name, Value: string); 51 | overload; 52 | procedure DisplayItem(const SG: TStringGrid; const Name: string; 53 | const Value: Boolean); overload; 54 | procedure DisplayItem(const SG: TStringGrid; const Name: string; 55 | const Value: Integer); overload; 56 | procedure DisplayItem(const SG: TStringGrid; const Name: string; 57 | const Value: TPJOSPlatform); overload; 58 | procedure DisplayItem(const SG: TStringGrid; const Name: string; 59 | const Value: TPJOSProduct); overload; 60 | procedure DisplayItem(const SG: TStringGrid; const Name: string; 61 | const Value: TBytes); overload; 62 | procedure DisplayItem(const SG: TStringGrid; const Name: string; 63 | const Value: TPJWin10PlusVersion); overload; 64 | procedure ShowContent(Tab: Integer); 65 | procedure ShowWin32Globals; 66 | procedure ShowTPJOSInfo; 67 | procedure ShowTPJComputerInfo; 68 | procedure ShowTPJSystemFolders; 69 | procedure ShowTPJBiosInfo; 70 | end; 71 | 72 | var 73 | Form1: TForm1; 74 | 75 | implementation 76 | 77 | uses 78 | Winapi.Windows, // for inlining 79 | System.DateUtils; 80 | 81 | 82 | {$R *.fmx} 83 | 84 | procedure TForm1.DisplayItem(const SG: TStringGrid; const Name: string; 85 | const Value: Integer); 86 | begin 87 | DisplayItem(SG, Name, IntToStr(Value)); 88 | end; 89 | 90 | procedure TForm1.DisplayItem(const SG: TStringGrid; const Name: string; 91 | const Value: TPJOSPlatform); 92 | const 93 | cOSPlatform: array[TPJOSPlatform] of string = ( 94 | 'ospWinNT', 'ospWin9x', 'ospWin32s' 95 | ); 96 | begin 97 | DisplayItem(SG, Name, cOSPlatform[Value]); 98 | end; 99 | 100 | procedure TForm1.DisplayItem(const SG: TStringGrid; const Name, Value: string); 101 | begin 102 | SG.RowCount := SG.RowCount + 1; 103 | SG.Cells[0, Pred(SG.RowCount)] := Name; 104 | SG.Cells[1, Pred(SG.RowCount)] := Value; 105 | end; 106 | 107 | procedure TForm1.DisplayItem(const SG: TStringGrid; const Name: string; 108 | const Value: Boolean); 109 | const 110 | cBoolean: array[Boolean] of string = ('False', 'True'); 111 | begin 112 | DisplayItem(SG, Name, cBoolean[Value]); 113 | end; 114 | 115 | procedure TForm1.DisplayItem(const SG: TStringGrid; const Name: string; 116 | const Value: TPJWin10PlusVersion); 117 | const 118 | cVersions: array[TPJWin10PlusVersion] of string = ( 119 | 'win10plusNA', 'win10plusUnknown', 120 | 'win10v1507', 'win10v1511', 'win10v1607', 'win10v1703', 'win10v1709', 121 | 'win10v1803', 'win10v1809', 'win10v1903', 'win10v1909', 'win10v2004', 122 | 'win10v20H2', 'win10v21H1', 'win10v21H2', 'win10v22H2', 123 | 'win11v21H2', 'win11v22H2', 'win11v23H2', 'win11v24H2' 124 | ); 125 | begin 126 | DisplayItem(SG, Name, cVersions[Value]); 127 | end; 128 | 129 | procedure TForm1.DisplayItem(const SG: TStringGrid; const Name: string; 130 | const Value: TPJOSProduct); 131 | const 132 | cOSProduct: array[TPJOSProduct] of string = ( 133 | 'osUnknownWinNT', 'osWinNT', 'osWin2K', 'osWinXP', 'osUnknownWin9x', 134 | 'osWin95', 'osWin98', 'osWinMe', 'osUnknownWin32s', 'osWinSvr2003', 135 | 'osUnknown', 'osWinVista', 'osWinSvr2003R2', 'osWinSvr2008', 136 | 'osWinLater', 'osWin7', 'osWinSvr2008R2', 'osWin8', 'osWinSvr2012', 137 | 'osWin8Point1', 'osWinSvr2012R2', 'osWin10', 'osWin10Svr', 'osWinSvr2019', 138 | 'osWin11', 'osWinSvr2022', 'osWinServer', 'osWinSvr2025', 'osWinSvrLater' 139 | ); 140 | begin 141 | DisplayItem(SG, Name, cOSProduct[Value]); 142 | end; 143 | 144 | procedure TForm1.DisplayItem(const SG: TStringGrid; const Name: string; 145 | const Value: TBytes); 146 | var 147 | B: Byte; 148 | S: string; 149 | begin 150 | S := ''; 151 | for B in Value do 152 | S := S + IntToHex(B) + ' '; 153 | S := Trim(S); 154 | DisplayItem(SG, Name, S); 155 | end; 156 | 157 | procedure TForm1.FormCreate(Sender: TObject); 158 | begin 159 | TabControl1.ActiveTab := tiComputerInfo; 160 | ShowContent(TabControl1.TabIndex); 161 | end; 162 | 163 | procedure TForm1.sgResized(Sender: TObject); 164 | var 165 | SG: TStringGrid; 166 | begin 167 | SG := Sender as TStringGrid; 168 | SG.Columns[1].Width := SG.Width - SG.Columns[0].Width - 8; 169 | end; 170 | 171 | procedure TForm1.ShowContent(Tab: Integer); 172 | begin 173 | case Tab of 174 | 0: ShowTPJComputerInfo; 175 | 1: ShowTPJBiosInfo; 176 | 2: ShowTPJSystemFolders; 177 | 3: ShowTPJOSInfo; 178 | 4: ShowWin32Globals; 179 | end; 180 | end; 181 | 182 | procedure TForm1.ShowTPJBiosInfo; 183 | const 184 | cWakeupTypes: array[TPJBIOSWakeupType] of string = ( 185 | 'wutReserved', 'wutOther', 'wutUnknown', 'wutAPMTimer', 'wutModemRing', 186 | 'wutLANRemote', 'wutPowerSwitch', 'wutPCIPME', 'wutACPowerRestored' 187 | ); 188 | 189 | function FmtVersionWord(const V: Word): string; 190 | begin 191 | if V <> 0 then 192 | Result := Format('$%.4x (v%d.%d)', [V, V shr 8, V and $FF]) 193 | else 194 | Result := 'Unknown or error'; 195 | end; 196 | 197 | function FmtDate(const D: TDate): string; 198 | var 199 | Fmt: TFormatSettings; 200 | begin 201 | // Use locale date format 202 | if SameDate(0.0, D) then 203 | Exit('Unknown or error'); 204 | Fmt := TFormatSettings.Create; 205 | Result := FormatDateTime(Fmt.ShortDateFormat, D); 206 | end; 207 | 208 | var 209 | BIOS: TPJBIOSInfo; 210 | begin 211 | sgBiosInfo.RowCount := 0; 212 | BIOS := TPJBIOSInfo.Create; 213 | try 214 | DisplayItem(sgBiosInfo, 'IsBIOSSupported', BIOS.IsBIOSSupported); 215 | DisplayItem(sgBiosInfo, 'SMBIOSSpecVersion', 216 | FmtVersionWord(BIOS.SMBIOSSpecVersion)); 217 | DisplayItem(sgBiosInfo, 'BIOSVendor', BIOS.BIOSVendor); 218 | DisplayItem(sgBiosInfo, 'BIOSVersionStr', BIOS.BIOSVersionStr); 219 | DisplayItem(sgBiosInfo, 'BIOSVersion', FmtVersionWord(BIOS.BIOSVersion)); 220 | DisplayItem(sgBiosInfo, 'BIOSECFirmwareVersion', 221 | FmtVersionWord(BIOS.BIOSECFirmwareVersion)); 222 | DisplayItem(sgBiosInfo, 'BIOSReleaseDate [current locale]', 223 | FmtDate(BIOS.BIOSReleaseDate)); 224 | DisplayItem(sgBiosInfo, 'BIOSReleaseDateInvariant', 225 | BIOS.BIOSReleaseDateInvariant); 226 | DisplayItem(sgBiosInfo, 'SystemUUIDRaw', BIOS.SystemUUIDRaw); 227 | DisplayItem(sgBiosInfo, 'SystemUUID [using GUIDToString]', 228 | GUIDToString(BIOS.SystemUUID)); 229 | DisplayItem(sgBiosInfo, 'SystemUUIDStr(False)', BIOS.SystemUUIDStr(False)); 230 | DisplayItem(sgBiosInfo, 'SystemUUIDStr(True)', BIOS.SystemUUIDStr(True)); 231 | DisplayItem(sgBiosInfo, 'SystemManufacturer', BIOS.SystemManufacturer); 232 | DisplayItem(sgBiosInfo, 'SystemProductName', BIOS.SystemProductName); 233 | DisplayItem(sgBiosInfo, 'SystemFamily', BIOS.SystemFamily); 234 | DisplayItem(sgBiosInfo, 'SystemOEMVersion', BIOS.SystemOEMVersion); 235 | DisplayItem(sgBiosInfo, 'SystemSerialNumber', BIOS.SystemSerialNumber); 236 | DisplayItem(sgBiosInfo, 'SystemSKUNumber', BIOS.SystemSKUNumber); 237 | DisplayItem(sgBiosInfo, 'SystemWakeupType', 238 | cWakeupTypes[BIOS.SystemWakeupType]); 239 | finally 240 | BIOS.Free; 241 | end; 242 | end; 243 | 244 | procedure TForm1.ShowTPJComputerInfo; 245 | const 246 | cProcessors: array[TPJProcessorArchitecture] of string = ( 247 | 'paUnknown', 'paX64', 'paIA64', 'paX86' 248 | ); 249 | cBootModes: array[TPJBootMode] of string = ( 250 | 'bmUnknown', 'bmNormal', 'bmSafeMode', 'bmSafeModeNetwork' 251 | ); 252 | begin 253 | sgComputerInfo.RowCount := 0; 254 | DisplayItem(sgComputerInfo, 'ComputerName', 255 | TPJComputerInfo.ComputerName); 256 | DisplayItem(sgComputerInfo, 'UserName', 257 | TPJComputerInfo.UserName); 258 | DisplayItem(sgComputerInfo, 'MACAddress', 259 | TPJComputerInfo.MACAddress); 260 | DisplayItem(sgComputerInfo, 'ProcessorCount', 261 | Integer(TPJComputerInfo.ProcessorCount)); 262 | DisplayItem(sgComputerInfo, 'Processor', 263 | cProcessors[TPJComputerInfo.Processor]); 264 | DisplayItem(sgComputerInfo, 'ProcessorIdentifier', 265 | TPJComputerInfo.ProcessorIdentifier); 266 | DisplayItem(sgComputerInfo, 'ProcessorName', TPJComputerInfo.ProcessorName); 267 | DisplayItem(sgComputerInfo, 'Processor Speed (MHz)', 268 | TPJComputerInfo.ProcessorSpeedMHz); 269 | DisplayItem(sgComputerInfo, 'Is64Bit', 270 | TPJComputerInfo.Is64Bit); 271 | DisplayItem(sgComputerInfo, 'IsNetworkPresent?', 272 | TPJComputerInfo.IsNetworkPresent); 273 | DisplayItem(sgComputerInfo, 'BootMode', cBootModes[TPJComputerInfo.BootMode]); 274 | DisplayItem(sgComputerInfo, 'IsAdmin', TPJComputerInfo.IsAdmin); 275 | DisplayItem(sgComputerInfo, 'IsUACActive', TPJComputerInfo.IsUACActive); 276 | DisplayItem(sgComputerInfo, 'BiosVendor', TPJComputerInfo.BiosVendor); 277 | DisplayItem(sgComputerInfo, 'SystemManufacturer', 278 | TPJComputerInfo.SystemManufacturer); 279 | DisplayItem(sgComputerInfo, 'SystemProductName', 280 | TPJComputerInfo.SystemProductName); 281 | end; 282 | 283 | procedure TForm1.ShowTPJOSInfo; 284 | begin 285 | sgOSInfo.RowCount := 0; 286 | DisplayItem(sgOSInfo, 'BuildNumber', TPJOSInfo.BuildNumber); 287 | DisplayItem(sgOSInfo, 'RevisionNumber', TPJOSInfo.RevisionNumber); 288 | DisplayItem(sgOSInfo, 'BuildBranch', TPJOSInfo.BuildBranch); 289 | DisplayItem(sgOSInfo, 'Description', TPJOSInfo.Description); 290 | DisplayItem(sgOSInfo, 'Edition', TPJOSInfo.Edition); 291 | if SameDateTime(TPJOSInfo.InstallationDate, 0.0) then 292 | DisplayItem(sgOSInfo, 'InstallationDate', 'Unknown') 293 | else 294 | DisplayItem(sgOSInfo, 'InstallationDate', 295 | DateTimeToStr(TPJOSInfo.InstallationDate)); 296 | DisplayItem(sgOSInfo, 'IsServer', TPJOSInfo.IsServer); 297 | DisplayItem(sgOSInfo, 'IsWin32s', TPJOSInfo.IsWin32s); 298 | DisplayItem(sgOSInfo, 'IsWin9x', TPJOSInfo.IsWin9x); 299 | DisplayItem(sgOSInfo, 'IsWinNT', TPJOSInfo.IsWinNT); 300 | DisplayItem(sgOSInfo, 'IsWow64', TPJOSInfo.IsWow64); 301 | DisplayItem(sgOSInfo, 'IsMediaCenter', TPJOSInfo.IsMediaCenter); 302 | DisplayItem(sgOSInfo, 'IsTabletPC', TPJOSInfo.IsTabletPC); 303 | DisplayItem(sgOSInfo, 'IsRemoteSession', TPJOSInfo.IsRemoteSession); 304 | DisplayItem(sgOSInfo, 'MajorVersion', TPJOSInfo.MajorVersion); 305 | DisplayItem(sgOSInfo, 'MinorVersion', TPJOSInfo.MinorVersion); 306 | DisplayItem(sgOSInfo, 'Platform', TPJOSInfo.Platform); 307 | DisplayItem(sgOSInfo, 'Product', TPJOSInfo.Product); 308 | DisplayItem(sgOSInfo, 'ProductName', TPJOSInfo.ProductName); 309 | DisplayItem(sgOSInfo, 'ServicePack', TPJOSInfo.ServicePack); 310 | DisplayItem(sgOSInfo, 'ServicePackEx', TPJOSInfo.ServicePackEx); 311 | DisplayItem(sgOSInfo, 'ServicePackMajor', TPJOSInfo.ServicePackMajor); 312 | DisplayItem(sgOSInfo, 'ServicePackMinor', TPJOSInfo.ServicePackMinor); 313 | DisplayItem(sgOSInfo, 'Windows10PlusVersion', 314 | TPJOSInfo.Windows10PlusVersion); 315 | DisplayItem(sgOSInfo, 'Windows10PlusVersionName', 316 | TPJOSInfo.Windows10PlusVersionName); 317 | DisplayItem(sgOSInfo, 'HasPenExtensions', TPJOSInfo.HasPenExtensions); 318 | DisplayItem(sgOSInfo, 'ProductID', TPJOSInfo.ProductID); 319 | DisplayItem(sgOSInfo, 'DigitalProductID', TPJOSInfo.DigitalProductID); 320 | DisplayItem(sgOSInfo, 'DecodedDigitalProductID', 321 | TPJOSInfo.DecodedDigitalProductID); 322 | DisplayItem(sgOSInfo, 'RegisteredOrganisation', 323 | TPJOSInfo.RegisteredOrganisation); 324 | DisplayItem(sgOSInfo, 'RegisteredOwner', TPJOSInfo.RegisteredOwner); 325 | DisplayItem(sgOSInfo, 'CanSpoof', TPJOSInfo.CanSpoof); 326 | DisplayItem(sgOSInfo, 'IsReallyWindows2000OrGreater', 327 | TPJOSInfo.IsReallyWindows2000OrGreater); 328 | DisplayItem(sgOSInfo, 'IsReallyWindows2000SP1OrGreater', 329 | TPJOSInfo.IsReallyWindows2000SP1OrGreater); 330 | DisplayItem(sgOSInfo, 'IsReallyWindows2000SP2OrGreater', 331 | TPJOSInfo.IsReallyWindows2000SP2OrGreater); 332 | DisplayItem(sgOSInfo, 'IsReallyWindows2000SP3OrGreater', 333 | TPJOSInfo.IsReallyWindows2000SP3OrGreater); 334 | DisplayItem(sgOSInfo, 'IsReallyWindows2000SP4OrGreater', 335 | TPJOSInfo.IsReallyWindows2000SP4OrGreater); 336 | DisplayItem(sgOSInfo, 'IsReallyWindowsXPOrGreater', 337 | TPJOSInfo.IsReallyWindowsXPOrGreater); 338 | DisplayItem(sgOSInfo, 'IsReallyWindowsXPSP1OrGreater', 339 | TPJOSInfo.IsReallyWindowsXPSP1OrGreater); 340 | DisplayItem(sgOSInfo, 'IsReallyWindowsXPSP2OrGreater', 341 | TPJOSInfo.IsReallyWindowsXPSP2OrGreater); 342 | DisplayItem(sgOSInfo, 'IsReallyWindowsXPSP3OrGreater', 343 | TPJOSInfo.IsReallyWindowsXPSP3OrGreater); 344 | DisplayItem(sgOSInfo, 'IsReallyWindowsVistaOrGreater', 345 | TPJOSInfo.IsReallyWindowsVistaOrGreater); 346 | DisplayItem(sgOSInfo, 'IsReallyWindowsVistaSP1OrGreater', 347 | TPJOSInfo.IsReallyWindowsVistaSP1OrGreater); 348 | DisplayItem(sgOSInfo, 'IsReallyWindowsVistaSP2OrGreater', 349 | TPJOSInfo.IsReallyWindowsVistaSP2OrGreater); 350 | DisplayItem(sgOSInfo, 'IsReallyWindows7OrGreater', 351 | TPJOSInfo.IsReallyWindows7OrGreater); 352 | DisplayItem(sgOSInfo, 'IsReallyWindows7SP1OrGreater', 353 | TPJOSInfo.IsReallyWindows7SP1OrGreater); 354 | DisplayItem(sgOSInfo, 'IsReallyWindows8OrGreater', 355 | TPJOSInfo.IsReallyWindows8OrGreater); 356 | DisplayItem(sgOSInfo, 'IsReallyWindows8Point1OrGreater', 357 | TPJOSInfo.IsReallyWindows8Point1OrGreater); 358 | DisplayItem(sgOSInfo, 'IsReallyWindows10OrGreater', 359 | TPJOSInfo.IsReallyWindows8OrGreater); 360 | DisplayItem(sgOSInfo, 'IsWindows10VersionOrLater(win10v1809)', 361 | TPJOSInfo.IsWindows10VersionOrLater(win10v1809)); 362 | DisplayItem(sgOSInfo, 'IsWindows10VersionOrLater(win10v22H2)', 363 | TPJOSInfo.IsWindows10VersionOrLater(win10v22H2)); 364 | DisplayItem(sgOSInfo, 'IsWindows11VersionOrLater(win11v23H2)', 365 | TPJOSInfo.IsWindows11VersionOrLater(win11v23H2)); 366 | DisplayItem(sgOSInfo, 'IsWindows11VersionOrLater(win11v24H2)', 367 | TPJOSInfo.IsWindows11VersionOrLater(win11v24H2)); 368 | DisplayItem(sgOSInfo, 'IsWindowsServer', TPJOSInfo.IsWindowsServer); 369 | end; 370 | 371 | procedure TForm1.ShowTPJSystemFolders; 372 | begin 373 | sgSpecialFolders.RowCount := 0; 374 | DisplayItem(sgSpecialFolders, 'CommonFiles', 375 | TPJSystemFolders.CommonFiles); 376 | DisplayItem(sgSpecialFolders, 'CommonFilesX86', 377 | TPJSystemFolders.CommonFilesX86); 378 | DisplayItem(sgSpecialFolders, 'CommonFilesRedirect', 379 | TPJSystemFolders.CommonFilesRedirect); 380 | DisplayItem(sgSpecialFolders, 'ProgramFiles', 381 | TPJSystemFolders.ProgramFiles); 382 | DisplayItem(sgSpecialFolders, 'ProgramFilesX86', 383 | TPJSystemFolders.ProgramFilesX86); 384 | DisplayItem(sgSpecialFolders, 'ProgramFilesRedirect', 385 | TPJSystemFolders.ProgramFilesRedirect); 386 | DisplayItem(sgSpecialFolders, 'Windows', TPJSystemFolders.Windows); 387 | DisplayItem(sgSpecialFolders, 'System', TPJSystemFolders.System); 388 | DisplayItem(sgSpecialFolders, 'SystemWow64', TPJSystemFolders.SystemWow64); 389 | DisplayItem(sgSpecialFolders, 'Temp', TPJSystemFolders.Temp); 390 | end; 391 | 392 | procedure TForm1.ShowWin32Globals; 393 | begin 394 | sgWin32Globals.RowCount := 0; 395 | DisplayItem(sgWin32Globals, 'Win32Platform', Win32Platform); 396 | DisplayItem(sgWin32Globals, 'Win32MajorVersion', Win32MajorVersion); 397 | DisplayItem(sgWin32Globals, 'Win32MinorVersion', Win32MinorVersion); 398 | DisplayItem(sgWin32Globals, 'Win32BuildNumber', Win32BuildNumber); 399 | DisplayItem(sgWin32Globals, 'Win32CSDVersion', Win32CSDVersion); 400 | 401 | DisplayItem(sgWin32Globals, 'Win32PlatformEx', Win32PlatformEx); 402 | DisplayItem(sgWin32Globals, 'Win32MajorVersionEx', Win32MajorVersionEx); 403 | DisplayItem(sgWin32Globals, 'Win32MinorVersionEx', Win32MinorVersionEx); 404 | DisplayItem(sgWin32Globals, 'Win32CSDVersionEx', Win32CSDVersionEx); 405 | DisplayItem(sgWin32Globals, 'Win32BuildNumberEx', Win32BuildNumberEx); 406 | 407 | DisplayItem(sgWin32Globals, 'Win32RevisionNumber', Win32RevisionNumber); 408 | 409 | DisplayItem(sgWin32Globals, 'Win32HaveExInfo', Win32HaveExInfo); 410 | DisplayItem(sgWin32Globals, 'Win32ProductType', Win32ProductType); 411 | DisplayItem(sgWin32Globals, 'Win32ServicePackMajor', Win32ServicePackMajor); 412 | DisplayItem(sgWin32Globals, 'Win32ServicePackMinor', Win32ServicePackMinor); 413 | DisplayItem(sgWin32Globals, 'Win32SuiteMask', Win32SuiteMask); 414 | DisplayItem(sgWin32Globals, 'Win32HaveProductInfo', Win32HaveProductInfo); 415 | DisplayItem(sgWin32Globals, 'Win32ProductInfo', Integer(Win32ProductInfo)); 416 | end; 417 | 418 | procedure TForm1.TabControl1Change(Sender: TObject); 419 | begin 420 | ShowContent(TabControl1.ActiveTab.Index); 421 | end; 422 | 423 | end. 424 | -------------------------------------------------------------------------------- /Demos/FMX/MainIcon.rc: -------------------------------------------------------------------------------- 1 | MAINICON ICON "FMXDemo_Icon.ico" 2 | -------------------------------------------------------------------------------- /Demos/FMX/MainIcon.res: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ddablib/sysinfo/4a7e984fae868a09b16a7fe2c69fdc5a9876145d/Demos/FMX/MainIcon.res -------------------------------------------------------------------------------- /Demos/FMX/Manifest.rc: -------------------------------------------------------------------------------- 1 | 1 24 "FMXDemo.manifest" 2 | -------------------------------------------------------------------------------- /Demos/FMX/Manifest.res: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ddablib/sysinfo/4a7e984fae868a09b16a7fe2c69fdc5a9876145d/Demos/FMX/Manifest.res -------------------------------------------------------------------------------- /Demos/ReadMe.txt: -------------------------------------------------------------------------------- 1 | Demo Programs for the PJSysInfo unit. 2 | ===================================== 3 | 4 | There are two demo programs, one in each of the VCL and FMX directories. Both 5 | demos display the result of calling every method of TPJComputerInfo, TPJOSInfo 6 | and TPJSystemFolders along with the values of all the Win32xxxx global 7 | variables. 8 | 9 | 1) VCL Directory 10 | 11 | The demo in the VCL directory compiles as a VCL program. 12 | 13 | This demo has been designed to be backward compatible with Delphi 4 and, 14 | later but this is not guaranteed. The current version has only been tested 15 | with Delphi XE, 11 and 12 using Windows 11 Version 23H2. 16 | 17 | Some unsupported form properties may need to be removed when opening the 18 | project's form in earlier compilers, but this should do no harm. 19 | 20 | Some compilers need some extra steps to be taken in order to compile the 21 | program: 22 | 23 | * For Delphi 2006 and earlier you need to manually create a Win32 sub- 24 | directory of the VCL directory to receive the output binaries. 25 | 26 | * Delphi 2007 cannot understand the project file. Delete the .dproj file and 27 | open the .bdsproj file instead. 28 | 29 | All supported compilers will output a Windows 32 bit program by default, in 30 | the Win32 sub-directory. 31 | 32 | Delphi XE2 and later can also create a 64 bit version of the program if the 33 | Windows 64 bit target is selected. 34 | 35 | ** BUG ** 36 | 64 bit programs are output to the Win32 sub-directory, not the Win64 sub- 37 | directory as may be expected. This bug is not being fixed because doing so 38 | **could** make that the project file incompatible with earlier Delphi 39 | versions. 40 | 41 | 2) FMX Directory 42 | 43 | This directory contains a demo program that compiles for the FireMonkey 2 44 | framework. 45 | 46 | The demo was initially created using Delphi XE3 and updated using Delphi XE4. 47 | It is believed that the demo is compatible with Delphi XE3 through to Delphi 48 | 11, but it has only been tested with Delphi 11 & 12 using Windows 11 49 | Version 23H2. 50 | 51 | When loaded into the IDE of Delphi version other than Delphi XE4, certain 52 | form properties may be reported as missing. Ignoring such properties should 53 | enable the form to load and the program to compile and run successfully. This 54 | is the case with Delphi 10.4 and 11. 55 | 56 | Both 32 bit and 64 bit Windows targets are supported, with 32 bit being the 57 | default. Binaries are written to the Win32 or Win64 sub-directories 58 | respectively. 59 | 60 | ## Note about manifests ## 61 | 62 | At least for Windows 10/11, TPJOSInfo returns different results depending on 63 | whether the host application is manifested to be compatible with that OS (this 64 | is a Microsoft "feature", no matter how ridiculous we may find it). 65 | 66 | Because of this each of the demo apps has a .manifest file that is included in 67 | its resources by means of a {$R 'Manifest.res} directive in the app's project 68 | file. To see how the values returned from TPJOSInfo methods change when there is 69 | no manifest simply comment out the {$R 'Manifest.res'} line and recompile. 70 | -------------------------------------------------------------------------------- /Demos/VCL/FmDemo.dfm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ddablib/sysinfo/4a7e984fae868a09b16a7fe2c69fdc5a9876145d/Demos/VCL/FmDemo.dfm -------------------------------------------------------------------------------- /Demos/VCL/FmDemo.pas: -------------------------------------------------------------------------------- 1 | { 2 | * FmDemo.pas 3 | * 4 | * Main form for System Information unit demo program. 5 | * 6 | * Any copyright in this file is dedicated to the Public Domain. 7 | * http://creativecommons.org/publicdomain/zero/1.0/ 8 | } 9 | 10 | 11 | unit FmDemo; 12 | 13 | interface 14 | 15 | uses 16 | SysUtils, StdCtrls, Classes, Controls, ComCtrls, Forms, ExtCtrls, 17 | Windows, {for inlining} 18 | PJSysInfo; 19 | 20 | type 21 | TDemoForm = class(TForm) 22 | TabControl1: TTabControl; 23 | edDisplay: TMemo; 24 | Bevel1: TBevel; 25 | procedure FormCreate(Sender: TObject); 26 | procedure TabControl1Change(Sender: TObject); 27 | private 28 | procedure DisplayRuling; 29 | procedure DisplayRuleOff; 30 | procedure DisplayHeading(const Title: string); 31 | procedure DisplayItem(const Name, Value: string); overload; 32 | procedure DisplayItem(const Name: string; const Value: Boolean); overload; 33 | procedure DisplayItem(const Name: string; const Value: Integer); overload; 34 | procedure DisplayItem(const Name: string; const Value: TPJOSPlatform); 35 | overload; 36 | procedure DisplayItem(const Name: string; const Value: TPJOSProduct); 37 | overload; 38 | procedure DisplayItem(const Name: string; const Value: TPJWin10PlusVersion); 39 | overload; 40 | procedure DisplayItem(const Name: string; const Value: TBytes); overload; 41 | procedure ShowContent(Tab: Integer); 42 | procedure ShowWin32Globals; 43 | procedure ShowTPJOSInfo; 44 | procedure ShowTPJComputerInfo; 45 | procedure ShowTPJSystemFolders; 46 | procedure ShowTPJBIOSInfo; 47 | end; 48 | 49 | var 50 | DemoForm: TDemoForm; 51 | 52 | implementation 53 | 54 | uses 55 | DateUtils; 56 | 57 | {$R *.DFM} 58 | 59 | const 60 | Column1Width = 38; // characters 61 | 62 | function SameDateTime(const A, B: TDateTime): Boolean; 63 | begin 64 | Result := Abs(A - B) < (1 / MSecsPerDay); 65 | end; 66 | 67 | procedure TDemoForm.DisplayHeading(const Title: string); 68 | begin 69 | if edDisplay.Lines.Count > 0 then 70 | edDisplay.Lines.Add(''); 71 | edDisplay.Lines.Add(Title); 72 | end; 73 | 74 | procedure TDemoForm.DisplayItem(const Name, Value: string); 75 | begin 76 | edDisplay.Lines.Add(Format('%-*s| %s', [Column1Width, Name, Value])); 77 | end; 78 | 79 | procedure TDemoForm.DisplayItem(const Name: string; const Value: Boolean); 80 | const 81 | cBoolean: array[Boolean] of string = ('False', 'True'); 82 | begin 83 | DisplayItem(Name, cBoolean[Value]); 84 | end; 85 | 86 | procedure TDemoForm.DisplayItem(const Name: string; const Value: Integer); 87 | begin 88 | DisplayItem(Name, IntToStr(Value)); 89 | end; 90 | 91 | procedure TDemoForm.DisplayItem(const Name: string; const Value: TPJOSPlatform); 92 | const 93 | cOSPlatform: array[TPJOSPlatform] of string = ( 94 | 'ospWinNT', 'ospWin9x', 'ospWin32s' 95 | ); 96 | begin 97 | DisplayItem(Name, cOSPlatform[Value]); 98 | end; 99 | 100 | procedure TDemoForm.DisplayItem(const Name: string; const Value: TPJOSProduct); 101 | const 102 | cOSProduct: array[TPJOSProduct] of string = ( 103 | 'osUnknownWinNT', 'osWinNT', 'osWin2K', 'osWinXP', 'osUnknownWin9x', 104 | 'osWin95', 'osWin98', 'osWinMe', 'osUnknownWin32s', 'osWinSvr2003', 105 | 'osUnknown', 'osWinVista', 'osWinSvr2003R2', 'osWinSvr2008', 106 | 'osWinLater', 'osWin7', 'osWinSvr2008R2', 'osWin8', 'osWinSvr2012', 107 | 'osWin8Point1', 'osWinSvr2012R2', 'osWin10', 'osWin10Svr', 'osWinSvr2019', 108 | 'osWin11', 'osWinSvr2022', 'osWinServer', 'osWinSvr2025', 'osWinSvrLater' 109 | ); 110 | begin 111 | DisplayItem(Name, cOSProduct[Value]); 112 | end; 113 | 114 | procedure TDemoForm.DisplayItem(const Name: string; const Value: TBytes); 115 | var 116 | B: Byte; 117 | S: string; 118 | begin 119 | S := ''; 120 | for B in Value do 121 | S := S + IntToHex(Integer(B), 2) + ' '; 122 | S := Trim(S); 123 | DisplayItem(Name, S); 124 | end; 125 | 126 | procedure TDemoForm.DisplayItem(const Name: string; 127 | const Value: TPJWin10PlusVersion); 128 | const 129 | cVersions: array[TPJWin10PlusVersion] of string = ( 130 | 'win10plusNA', 'win10plusUnknown', 131 | 'win10v1507', 'win10v1511', 'win10v1607', 'win10v1703', 'win10v1709', 132 | 'win10v1803', 'win10v1809', 'win10v1903', 'win10v1909', 'win10v2004', 133 | 'win10v20H2', 'win10v21H1', 'win10v21H2', 'win10v22H2', 134 | 'win11v21H2', 'win11v22H2', 'win11v23H2', 'win11v24H2' 135 | ); 136 | begin 137 | DisplayItem(Name, cVersions[Value]); 138 | end; 139 | 140 | procedure TDemoForm.DisplayRuleOff; 141 | begin 142 | edDisplay.Lines.Add(StringOfChar('=', Column1Width) + '+' 143 | + StringOfChar('=', 55)); 144 | end; 145 | 146 | procedure TDemoForm.DisplayRuling; 147 | begin 148 | edDisplay.Lines.Add(StringOfChar('-', Column1Width) + '+' 149 | + StringOfChar('-', 55)); 150 | end; 151 | 152 | procedure TDemoForm.FormCreate(Sender: TObject); 153 | begin 154 | ShowContent(TabControl1.TabIndex); 155 | end; 156 | 157 | procedure TDemoForm.ShowContent(Tab: Integer); 158 | begin 159 | edDisplay.Lines.BeginUpdate; 160 | try 161 | edDisplay.Clear; 162 | case Tab of 163 | 0: ShowTPJComputerInfo; 164 | 1: ShowTPJBIOSInfo; 165 | 2: ShowTPJSystemFolders; 166 | 3: ShowTPJOSInfo; 167 | 4: ShowWin32Globals; 168 | end; 169 | finally 170 | edDisplay.Lines.EndUpdate; 171 | end; 172 | end; 173 | 174 | procedure TDemoForm.ShowTPJBIOSInfo; 175 | const 176 | cWakeupTypes: array[TPJBIOSWakeupType] of string = ( 177 | 'wutReserved', 'wutOther', 'wutUnknown', 'wutAPMTimer', 'wutModemRing', 178 | 'wutLANRemote', 'wutPowerSwitch', 'wutPCIPME', 'wutACPowerRestored' 179 | ); 180 | 181 | function FmtVersionWord(const V: Word): string; 182 | begin 183 | if V <> 0 then 184 | Result := Format('$%.4x (v%d.%d)', [V, V shr 8, V and $FF]) 185 | else 186 | Result := 'Unknown or error'; 187 | end; 188 | 189 | function FmtDate(const D: TDate): string; 190 | var 191 | Fmt: TFormatSettings; 192 | begin 193 | // Use locale date format 194 | if SameDate(0.0, D) then 195 | Exit('Unknown or error'); 196 | Fmt := TFormatSettings.Create; 197 | Result := FormatDateTime(Fmt.ShortDateFormat, D); 198 | end; 199 | 200 | var 201 | BIOS: TPJBIOSInfo; 202 | begin 203 | BIOS := TPJBIOSInfo.Create; 204 | try 205 | DisplayHeading('TPJBIOSInfo Methods'); 206 | DisplayRuling; 207 | DisplayItem('IsBIOSSupported', BIOS.IsBIOSSupported); 208 | DisplayItem('SMBIOSSpecVersion', FmtVersionWord(BIOS.SMBIOSSpecVersion)); 209 | DisplayRuling; 210 | DisplayItem('BIOSVendor', BIOS.BIOSVendor); 211 | DisplayItem('BIOSVersionStr', BIOS.BIOSVersionStr); 212 | DisplayItem('BIOSVersion', FmtVersionWord(BIOS.BIOSVersion)); 213 | DisplayItem('BIOSECFirmwareVersion', 214 | FmtVersionWord(BIOS.BIOSECFirmwareVersion)); 215 | DisplayItem('BIOSReleaseDate [current locale]', 216 | FmtDate(BIOS.BIOSReleaseDate)); 217 | DisplayItem('BIOSReleaseDateInvariant', BIOS.BIOSReleaseDateInvariant); 218 | DisplayRuling; 219 | DisplayItem('SystemUUIDRaw', BIOS.SystemUUIDRaw); 220 | DisplayItem('SystemUUID [using GUIDToString]', 221 | GUIDToString(BIOS.SystemUUID)); 222 | DisplayItem('SystemUUIDStr(False)', BIOS.SystemUUIDStr(False)); 223 | DisplayItem('SystemUUIDStr(True)', BIOS.SystemUUIDStr(True)); 224 | DisplayItem('SystemManufacturer', BIOS.SystemManufacturer); 225 | DisplayItem('SystemProductName', BIOS.SystemProductName); 226 | DisplayItem('SystemFamily', BIOS.SystemFamily); 227 | DisplayItem('SystemOEMVersion', BIOS.SystemOEMVersion); 228 | DisplayItem('SystemSerialNumber', BIOS.SystemSerialNumber); 229 | DisplayItem('SystemSKUNumber', BIOS.SystemSKUNumber); 230 | DisplayItem('SystemWakeupType', cWakeupTypes[BIOS.SystemWakeupType]); 231 | DisplayRuleOff; 232 | finally 233 | BIOS.Free; 234 | end; 235 | end; 236 | 237 | procedure TDemoForm.ShowTPJComputerInfo; 238 | const 239 | cProcessors: array[TPJProcessorArchitecture] of string = ( 240 | 'paUnknown', 'paX64', 'paIA64', 'paX86' 241 | ); 242 | cBootModes: array[TPJBootMode] of string = ( 243 | 'bmUnknown', 'bmNormal', 'bmSafeMode', 'bmSafeModeNetwork' 244 | ); 245 | begin 246 | DisplayHeading('TPJComputerInfo Static Methods'); 247 | DisplayRuling; 248 | DisplayItem('ComputerName', TPJComputerInfo.ComputerName); 249 | DisplayItem('UserName', TPJComputerInfo.UserName); 250 | DisplayItem('MACAddress', TPJComputerInfo.MACAddress); 251 | DisplayItem('ProcessorCount', Integer(TPJComputerInfo.ProcessorCount)); 252 | DisplayItem('Processor', cProcessors[TPJComputerInfo.Processor]); 253 | DisplayItem('ProcessorIdentifier', TPJComputerInfo.ProcessorIdentifier); 254 | DisplayItem('ProcessorName', TPJComputerInfo.ProcessorName); 255 | DisplayItem('ProcessorSpeedMHz', TPJComputerInfo.ProcessorSpeedMHz); 256 | DisplayItem('Is64Bit', TPJComputerInfo.Is64Bit); 257 | DisplayItem('IsNetworkPresent', TPJComputerInfo.IsNetworkPresent); 258 | DisplayItem('BootMode', cBootModes[TPJComputerInfo.BootMode]); 259 | DisplayItem('IsAdmin', TPJComputerInfo.IsAdmin); 260 | DisplayItem('IsUACActive', TPJComputerInfo.IsUACActive); 261 | DisplayItem('BiosVendor', TPJComputerInfo.BiosVendor); 262 | DisplayItem('SystemManufacturer', TPJComputerInfo.SystemManufacturer); 263 | DisplayItem('SystemProductName', TPJComputerInfo.SystemProductName); 264 | DisplayRuleOff; 265 | end; 266 | 267 | procedure TDemoForm.ShowTPJOSInfo; 268 | begin 269 | DisplayHeading('TPJOSInfo Static Methods'); 270 | DisplayRuling; 271 | DisplayItem('BuildNumber', TPJOSInfo.BuildNumber); 272 | DisplayItem('RevisionNumber', TPJOSInfo.RevisionNumber); 273 | DisplayItem('BuildBranch', TPJOSInfo.BuildBranch); 274 | DisplayItem('Description', TPJOSInfo.Description); 275 | DisplayItem('Edition', TPJOSInfo.Edition); 276 | if SameDateTime(TPJOSInfo.InstallationDate, 0.0) then 277 | DisplayItem('InstallationDate', 'Unknown') 278 | else 279 | DisplayItem('InstallationDate', DateTimeToStr(TPJOSInfo.InstallationDate)); 280 | DisplayItem('IsServer', TPJOSInfo.IsServer); 281 | DisplayItem('IsWin32s', TPJOSInfo.IsWin32s); 282 | DisplayItem('IsWin9x', TPJOSInfo.IsWin9x); 283 | DisplayItem('IsWinNT', TPJOSInfo.IsWinNT); 284 | DisplayItem('IsWow64', TPJOSInfo.IsWow64); 285 | DisplayItem('IsMediaCenter', TPJOSInfo.IsMediaCenter); 286 | DisplayItem('IsTabletPC', TPJOSInfo.IsTabletPC); 287 | DisplayItem('IsRemoteSession', TPJOSInfo.IsRemoteSession); 288 | DisplayItem('MajorVersion', TPJOSInfo.MajorVersion); 289 | DisplayItem('MinorVersion', TPJOSInfo.MinorVersion); 290 | DisplayItem('Platform', TPJOSInfo.Platform); 291 | DisplayItem('Product', TPJOSInfo.Product); 292 | DisplayItem('ProductName', TPJOSInfo.ProductName); 293 | DisplayItem('ServicePack', TPJOSInfo.ServicePack); 294 | DisplayItem('ServicePackEx', TPJOSInfo.ServicePackEx); 295 | DisplayItem('ServicePackMajor', TPJOSInfo.ServicePackMajor); 296 | DisplayItem('ServicePackMinor', TPJOSInfo.ServicePackMinor); 297 | DisplayItem('Windows10PlusVersion', 298 | TPJOSInfo.Windows10PlusVersion); 299 | DisplayItem('Windows10PlusVersionName', 300 | TPJOSInfo.Windows10PlusVersionName); 301 | DisplayItem('HasPenExtensions', TPJOSInfo.HasPenExtensions); 302 | DisplayItem('ProductID', TPJOSInfo.ProductID); 303 | DisplayItem('DigitalProductID', TPJOSInfo.DigitalProductID); 304 | DisplayItem('DecodedDigitalProductID', TPJOSInfo.DecodedDigitalProductID); 305 | DisplayItem('RegisteredOrganisation', TPJOSInfo.RegisteredOrganisation); 306 | DisplayItem('RegisteredOwner', TPJOSInfo.RegisteredOwner); 307 | DisplayRuling; 308 | DisplayItem('CanSpoof', TPJOSInfo.CanSpoof); 309 | DisplayItem('IsReallyWindows2000OrGreater', 310 | TPJOSInfo.IsReallyWindows2000OrGreater); 311 | DisplayItem('IsReallyWindows2000SP1OrGreater', 312 | TPJOSInfo.IsReallyWindows2000SP1OrGreater); 313 | DisplayItem('IsReallyWindows2000SP2OrGreater', 314 | TPJOSInfo.IsReallyWindows2000SP2OrGreater); 315 | DisplayItem('IsReallyWindows2000SP3OrGreater', 316 | TPJOSInfo.IsReallyWindows2000SP3OrGreater); 317 | DisplayItem('IsReallyWindows2000SP4OrGreater', 318 | TPJOSInfo.IsReallyWindows2000SP4OrGreater); 319 | DisplayItem('IsReallyWindowsXPOrGreater', 320 | TPJOSInfo.IsReallyWindowsXPOrGreater); 321 | DisplayItem('IsReallyWindowsXPSP1OrGreater', 322 | TPJOSInfo.IsReallyWindowsXPSP1OrGreater); 323 | DisplayItem('IsReallyWindowsXPSP2OrGreater', 324 | TPJOSInfo.IsReallyWindowsXPSP2OrGreater); 325 | DisplayItem('IsReallyWindowsXPSP3OrGreater', 326 | TPJOSInfo.IsReallyWindowsXPSP3OrGreater); 327 | DisplayItem('IsReallyWindowsVistaOrGreater', 328 | TPJOSInfo.IsReallyWindowsVistaOrGreater); 329 | DisplayItem('IsReallyWindowsVistaSP1OrGreater', 330 | TPJOSInfo.IsReallyWindowsVistaSP1OrGreater); 331 | DisplayItem('IsReallyWindowsVistaSP2OrGreater', 332 | TPJOSInfo.IsReallyWindowsVistaSP2OrGreater); 333 | DisplayItem('IsReallyWindows7OrGreater', 334 | TPJOSInfo.IsReallyWindows7OrGreater); 335 | DisplayItem('IsReallyWindows7SP1OrGreater', 336 | TPJOSInfo.IsReallyWindows7SP1OrGreater); 337 | DisplayItem('IsReallyWindows8OrGreater', 338 | TPJOSInfo.IsReallyWindows8OrGreater); 339 | DisplayItem('IsReallyWindows8Point1OrGreater', 340 | TPJOSInfo.IsReallyWindows8Point1OrGreater); 341 | DisplayItem('IsReallyWindows10OrGreater', 342 | TPJOSInfo.IsReallyWindows10OrGreater); 343 | DisplayItem('IsWindows10VersionOrLater(win10v1809)', 344 | TPJOSInfo.IsWindows10VersionOrLater(win10v1809)); 345 | DisplayItem('IsWindows10VersionOrLater(win10v22H2)', 346 | TPJOSInfo.IsWindows10VersionOrLater(win10v22H2)); 347 | DisplayItem('IsWindows11VersionOrLater(win11v23H2)', 348 | TPJOSInfo.IsWindows11VersionOrLater(win11v23H2)); 349 | DisplayItem('IsWindows11VersionOrLater(win11v24H2)', 350 | TPJOSInfo.IsWindows11VersionOrLater(win11v24H2)); 351 | DisplayItem('IsWindowsServer', TPJOSInfo.IsWindowsServer); 352 | DisplayRuleOff; 353 | end; 354 | 355 | procedure TDemoForm.ShowTPJSystemFolders; 356 | begin 357 | DisplayHeading('TPJSystemFolders Static Methods'); 358 | DisplayRuling; 359 | DisplayItem('CommonFiles', TPJSystemFolders.CommonFiles); 360 | DisplayItem('CommonFilesX86', TPJSystemFolders.CommonFilesX86); 361 | DisplayItem('CommonFilesRedirect', TPJSystemFolders.CommonFilesRedirect); 362 | DisplayRuling; 363 | DisplayItem('ProgramFiles', TPJSystemFolders.ProgramFiles); 364 | DisplayItem('ProgramFilesX86', TPJSystemFolders.ProgramFilesX86); 365 | DisplayItem('ProgramFilesRedirect', TPJSystemFolders.ProgramFilesRedirect); 366 | DisplayRuling; 367 | DisplayItem('Windows', TPJSystemFolders.Windows); 368 | DisplayItem('System', TPJSystemFolders.System); 369 | DisplayItem('SystemWow64', TPJSystemFolders.SystemWow64); 370 | DisplayRuling; 371 | DisplayItem('Temp', TPJSystemFolders.Temp); 372 | DisplayRuleOff; 373 | end; 374 | 375 | procedure TDemoForm.ShowWin32Globals; 376 | begin 377 | DisplayHeading('SysUtils Win32XXX Variables'); 378 | DisplayRuling; 379 | DisplayItem('Win32Platform', Win32Platform); 380 | DisplayItem('Win32MajorVersion', Win32MajorVersion); 381 | DisplayItem('Win32MinorVersion', Win32MinorVersion); 382 | DisplayItem('Win32BuildNumber', Win32BuildNumber); 383 | DisplayItem('Win32CSDVersion', Win32CSDVersion); 384 | DisplayRuleOff; 385 | 386 | DisplayHeading('PJSysInfo Win32XXX Variables'); 387 | DisplayRuling; 388 | DisplayItem('Win32PlatformEx', Win32PlatformEx); 389 | DisplayItem('Win32MajorVersionEx', Win32MajorVersionEx); 390 | DisplayItem('Win32MinorVersionEx', Win32MinorVersionEx); 391 | DisplayItem('Win32BuildNumberEx', Win32BuildNumberEx); 392 | DisplayItem('Win32CSDVersionEx', Win32CSDVersionEx); 393 | DisplayItem('Win32RevisionNumber', Win32RevisionNumber); 394 | DisplayRuling; 395 | DisplayItem('Win32HaveExInfo', Win32HaveExInfo); 396 | DisplayItem('Win32ProductType', Win32ProductType); 397 | DisplayItem('Win32ServicePackMajor', Win32ServicePackMajor); 398 | DisplayItem('Win32ServicePackMinor', Win32ServicePackMinor); 399 | DisplayItem('Win32SuiteMask', Win32SuiteMask); 400 | DisplayItem('Win32HaveProductInfo', Win32HaveProductInfo); 401 | DisplayItem('Win32ProductInfo', Integer(Win32ProductInfo)); 402 | DisplayRuleOff; 403 | 404 | end; 405 | 406 | procedure TDemoForm.TabControl1Change(Sender: TObject); 407 | begin 408 | ShowContent(TabControl1.TabIndex); 409 | end; 410 | 411 | end. 412 | 413 | -------------------------------------------------------------------------------- /Demos/VCL/MainIcon.rc: -------------------------------------------------------------------------------- 1 | MAINICON ICON "SysInfoDemo_Icon.ico" 2 | -------------------------------------------------------------------------------- /Demos/VCL/MainIcon.res: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ddablib/sysinfo/4a7e984fae868a09b16a7fe2c69fdc5a9876145d/Demos/VCL/MainIcon.res -------------------------------------------------------------------------------- /Demos/VCL/Manifest.rc: -------------------------------------------------------------------------------- 1 | 1 24 "SysInfoDemo.manifest" 2 | -------------------------------------------------------------------------------- /Demos/VCL/Manifest.res: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ddablib/sysinfo/4a7e984fae868a09b16a7fe2c69fdc5a9876145d/Demos/VCL/Manifest.res -------------------------------------------------------------------------------- /Demos/VCL/SysInfoDemo.bdsproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | SysInfoDemo.dpr 14 | 15 | 16 | 7.0 17 | 18 | 19 | 8 20 | 0 21 | 1 22 | 1 23 | 0 24 | 0 25 | 1 26 | 1 27 | 1 28 | 0 29 | 0 30 | 1 31 | 0 32 | 1 33 | 1 34 | 1 35 | 0 36 | 0 37 | 0 38 | 0 39 | 0 40 | 1 41 | 0 42 | 1 43 | 1 44 | 1 45 | True 46 | True 47 | 48 | 49 | False 50 | 51 | False 52 | False 53 | False 54 | True 55 | False 56 | False 57 | False 58 | True 59 | True 60 | True 61 | True 62 | True 63 | True 64 | True 65 | True 66 | True 67 | True 68 | True 69 | True 70 | True 71 | True 72 | True 73 | True 74 | True 75 | True 76 | True 77 | True 78 | True 79 | True 80 | True 81 | True 82 | True 83 | True 84 | True 85 | True 86 | True 87 | True 88 | True 89 | True 90 | True 91 | True 92 | True 93 | True 94 | True 95 | True 96 | True 97 | False 98 | False 99 | False 100 | True 101 | True 102 | True 103 | True 104 | True 105 | True 106 | 107 | 108 | 109 | 0 110 | 0 111 | False 112 | 1 113 | False 114 | False 115 | False 116 | 16384 117 | 1048576 118 | 4194304 119 | 120 | 121 | 122 | .\Win32 123 | .\Win32 124 | 125 | 126 | 127 | vcl;rtl;vclx;indy;vclie;xmlrtl;inetdbbde;inet;inetdbxpress;dbrtl;soaprtl;dsnap;VclSmp;dbexpress;vcldb;dbxcds;inetdb;bdertl;vcldbx;adortl;teeui;teedb;tee;ibxpress;visualclx;visualdbclx;vclactnband;vclshlctrls 128 | 129 | 130 | False 131 | 132 | 133 | 134 | 135 | 136 | False 137 | 138 | 139 | True 140 | False 141 | 142 | 143 | False 144 | False 145 | 1 146 | 0 147 | 0 148 | 0 149 | False 150 | False 151 | False 152 | False 153 | False 154 | 2057 155 | 1252 156 | 157 | 158 | 159 | 160 | 1.0.0.0 161 | 162 | 163 | 164 | 165 | 166 | 1.0.0.0 167 | 168 | 169 | 170 | 171 | -------------------------------------------------------------------------------- /Demos/VCL/SysInfoDemo.cfg: -------------------------------------------------------------------------------- 1 | -$A8 2 | -$B- 3 | -$C+ 4 | -$D+ 5 | -$E- 6 | -$F- 7 | -$G+ 8 | -$H+ 9 | -$I+ 10 | -$J- 11 | -$K- 12 | -$L+ 13 | -$M- 14 | -$N+ 15 | -$O+ 16 | -$P+ 17 | -$Q- 18 | -$R- 19 | -$S- 20 | -$T- 21 | -$U- 22 | -$V+ 23 | -$W- 24 | -$X+ 25 | -$YD 26 | -$Z1 27 | -cg 28 | -H+ 29 | -W+ 30 | -M 31 | -$M16384,1048576 32 | -K$00400000 33 | -E".\Win32" 34 | -N".\Win32" 35 | -LE"" 36 | -LN"" 37 | -------------------------------------------------------------------------------- /Demos/VCL/SysInfoDemo.dof: -------------------------------------------------------------------------------- 1 | [FileVersion] 2 | Version=7.0 3 | [Compiler] 4 | A=8 5 | B=0 6 | C=1 7 | D=1 8 | E=0 9 | F=0 10 | G=1 11 | H=1 12 | I=1 13 | J=0 14 | K=0 15 | L=1 16 | M=0 17 | N=1 18 | O=1 19 | P=1 20 | Q=0 21 | R=0 22 | S=0 23 | T=0 24 | U=0 25 | V=1 26 | W=0 27 | X=1 28 | Y=1 29 | Z=1 30 | ShowHints=1 31 | ShowWarnings=1 32 | UnitAliases= 33 | NamespacePrefix= 34 | SymbolDeprecated=0 35 | SymbolLibrary=0 36 | SymbolPlatform=0 37 | UnitLibrary=0 38 | UnitPlatform=0 39 | UnitDeprecated=0 40 | HResultCompat=1 41 | HidingMember=1 42 | HiddenVirtual=1 43 | Garbage=1 44 | BoundsError=1 45 | ZeroNilCompat=1 46 | StringConstTruncated=1 47 | ForLoopVarVarPar=1 48 | TypedConstVarPar=1 49 | AsgToTypedConst=1 50 | CaseLabelRange=1 51 | ForVariable=1 52 | ConstructingAbstract=1 53 | ComparisonFalse=1 54 | ComparisonTrue=1 55 | ComparingSignedUnsigned=1 56 | CombiningSignedUnsigned=1 57 | UnsupportedConstruct=1 58 | FileOpen=1 59 | FileOpenUnitSrc=1 60 | BadGlobalSymbol=1 61 | DuplicateConstructorDestructor=1 62 | InvalidDirective=1 63 | PackageNoLink=1 64 | PackageThreadVar=1 65 | ImplicitImport=1 66 | HPPEMITIgnored=1 67 | NoRetVal=1 68 | UseBeforeDef=1 69 | ForLoopVarUndef=1 70 | UnitNameMismatch=1 71 | NoCFGFileFound=1 72 | MessageDirective=1 73 | ImplicitVariants=1 74 | UnicodeToLocale=1 75 | LocaleToUnicode=1 76 | ImagebaseMultiple=1 77 | SuspiciousTypecast=1 78 | PrivatePropAccessor=1 79 | UnsafeType=0 80 | UnsafeCode=0 81 | UnsafeCast=0 82 | [Linker] 83 | MapFile=0 84 | OutputObjs=0 85 | ConsoleApp=1 86 | DebugInfo=0 87 | RemoteSymbols=0 88 | MinStackSize=16384 89 | MaxStackSize=1048576 90 | ImageBase=4194304 91 | ExeDescription= 92 | [Directories] 93 | OutputDir=.\Win32 94 | UnitOutputDir=.\Win32 95 | PackageDLLOutputDir= 96 | PackageDCPOutputDir= 97 | SearchPath= 98 | Packages=vcl;rtl;vclx;indy;vclie;xmlrtl;inetdbbde;inet;inetdbxpress;dbrtl;soaprtl;dsnap;VclSmp;dbexpress;vcldb;dbxcds;inetdb;bdertl;vcldbx;adortl;teeui;teedb;tee;ibxpress;visualclx;visualdbclx;vclactnband;vclshlctrls 99 | Conditionals= 100 | DebugSourceDirs= 101 | UsePackages=0 102 | [Parameters] 103 | RunParams= 104 | HostApplication= 105 | Launcher= 106 | UseLauncher=0 107 | DebugCWD= 108 | [Language] 109 | ActiveLang= 110 | ProjectLang= 111 | RootDir= 112 | [Version Info] 113 | IncludeVerInfo=0 114 | AutoIncBuild=0 115 | MajorVer=1 116 | MinorVer=0 117 | Release=0 118 | Build=0 119 | Debug=0 120 | PreRelease=0 121 | Special=0 122 | Private=0 123 | DLL=0 124 | Locale=2057 125 | CodePage=1252 126 | [Version Info Keys] 127 | CompanyName= 128 | FileDescription= 129 | FileVersion=1.0.0.0 130 | InternalName= 131 | LegalCopyright= 132 | LegalTrademarks= 133 | OriginalFilename= 134 | ProductName= 135 | ProductVersion=1.0.0.0 136 | Comments= 137 | -------------------------------------------------------------------------------- /Demos/VCL/SysInfoDemo.dpr: -------------------------------------------------------------------------------- 1 | { 2 | * SysInfoDemo.dpr 3 | * 4 | * Project file for System Information Unit demo program. 5 | * 6 | * Any copyright in this file is dedicated to the Public Domain. 7 | * http://creativecommons.org/publicdomain/zero/1.0/ 8 | } 9 | 10 | 11 | program SysInfoDemo; 12 | 13 | uses 14 | Forms, 15 | FmDemo in 'FmDemo.pas' {DemoForm}, 16 | PJSysInfo in '..\..\PJSysInfo.pas'; 17 | 18 | {$R 'MainIcon.res'} 19 | {$R 'Manifest.res'} 20 | 21 | begin 22 | Application.Initialize; 23 | Application.CreateForm(TDemoForm, DemoForm); 24 | Application.Run; 25 | end. 26 | 27 | -------------------------------------------------------------------------------- /Demos/VCL/SysInfoDemo.dproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | {EE476DDE-6327-47F2-B0CA-3CAB54243CB3} 4 | SysInfoDemo.dpr 5 | True 6 | Base 7 | 3 8 | Application 9 | VCL 10 | 14.4 11 | Win32 12 | Win32 13 | DCC32 14 | 15 | 16 | true 17 | 18 | 19 | .\Win32 20 | .\Win32 21 | 1 22 | true 23 | false 24 | vcl;rtl;vclx;indy;vclie;xmlrtl;inetdbbde;inet;inetdbxpress;dbrtl;soaprtl;dsnap;VclSmp;dbexpress;vcldb;dbxcds;inetdb;bdertl;vcldbx;adortl;teeui;teedb;tee;ibxpress;visualclx;visualdbclx;vclactnband;vclshlctrls;$(DCC_UsePackage) 25 | false 26 | Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;System;Xml;Data;Datasnap;Web;Soap;Winapi;System.Win;$(DCC_Namespace) 27 | 00400000 28 | None 29 | SysInfoDemo_Icon.ico 30 | false 31 | false 32 | false 33 | false 34 | false 35 | false 36 | false 37 | 2057 38 | CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments= 39 | false 40 | 41 | 42 | 43 | MainSource 44 | 45 | 46 |
DemoForm
47 |
48 | 49 | 50 | Base 51 | 52 |
53 | 54 | 55 | 56 | Delphi.Personality.12 57 | 58 | 59 | 60 | 61 | SysInfoDemo.dpr 62 | 63 | 64 | False 65 | False 66 | 1 67 | 0 68 | 0 69 | 0 70 | False 71 | False 72 | False 73 | False 74 | False 75 | 2057 76 | 1252 77 | 78 | 79 | 80 | 81 | 1.0.0.0 82 | 83 | 84 | 85 | 86 | 87 | 1.0.0.0 88 | 89 | 90 | 91 | Microsoft Office 2000 Sample Automation Server Wrapper Components 92 | Microsoft Office XP Sample Automation Server Wrapper Components 93 | 94 | 95 | 96 | True 97 | True 98 | 99 | 100 | 12 101 | 102 |
103 | -------------------------------------------------------------------------------- /Demos/VCL/SysInfoDemo.manifest: -------------------------------------------------------------------------------- 1 |  2 | 3 | 8 | System Info Demo by DelphiDabbler 9 | 10 | 11 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /Demos/VCL/SysInfoDemo_Icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ddablib/sysinfo/4a7e984fae868a09b16a7fe2c69fdc5a9876145d/Demos/VCL/SysInfoDemo_Icon.ico -------------------------------------------------------------------------------- /DevTools/Release.bat: -------------------------------------------------------------------------------- 1 | @rem --------------------------------------------------------------------------- 2 | @rem Script used to create zip file containing source code of System Information 3 | @rem Classes. 4 | @rem 5 | @rem Requirements: 6 | @rem 7 | @rem 1) This script uses the zip.exe program to create the release zip file. 8 | @rem 9 | @rem 2) If the ZIPPATH environment variable exists it must provide the path to 10 | @rem the directory where zip.exe is located. ZIPPATH *must not* have a 11 | @rem trailing backslash. If ZIPPATH does not exist then Zip.exe is expected 12 | @rem to be on the path. 13 | @rem 14 | @rem 3) A release version number may be provided as a parameter to the script. 15 | @rem When present the version number is included in the name of the zip file 16 | @rem that is created. 17 | @rem 18 | @rem Any copyright in this file is dedicated to the Public Domain. 19 | @rem http://creativecommons.org/publicdomain/zero/1.0/ 20 | @rem --------------------------------------------------------------------------- 21 | 22 | @echo off 23 | 24 | setlocal 25 | 26 | cd .. 27 | 28 | set SrcDir= 29 | set DocsDir=Docs 30 | set DemoDir=Demos 31 | 32 | set OutFile=Release\dd-sysinfo 33 | if not "%1" == "" set OutFile=%OutFile%-%1 34 | set OutFile=%OutFile%.zip 35 | echo Output file name = %OutFile% 36 | if exist %OutFile% del %OutFile% 37 | 38 | if not "%ZIPPATH%" == "" set ZIPPATH=%ZIPPATH%\ 39 | echo Zip path = %ZIPPATH% 40 | 41 | if exist Release rmdir /S /Q Release 42 | mkdir Release 43 | 44 | %ZIPPATH%Zip.exe -j -9 %OutFile% PJSysInfo.pas 45 | 46 | %ZIPPATH%Zip.exe -j -9 %OutFile% CHANGELOG.md 47 | %ZIPPATH%Zip.exe -j -9 %OutFile% README.md 48 | %ZIPPATH%Zip.exe -j -9 %OutFile% %DocsDir%\MPL-2.0.txt 49 | %ZIPPATH%Zip.exe -j -9 %OutFile% %DocsDir%\Documentation.URL 50 | 51 | %ZIPPATH%Zip.exe %OutFile% -r -9 %DemoDir%\*.* 52 | 53 | endlocal 54 | -------------------------------------------------------------------------------- /Docs/Acknowledgements.md: -------------------------------------------------------------------------------- 1 | # Acknowledgements 2 | 3 | Thanks to the following who have contributed to this project: 4 | 5 | * _**Guillermo Fazzolari**_ for the bug fix in v2.0.1. 6 | 7 | * _**Laurent Pierre**_ supplied many `PRODUCT_*` constants and suggested the _GetProductInfo_ API code used in v3.0 and later. 8 | 9 | * _**Rich Habedank**_ for the bug fix in Subversion revision 228 (now Git commit 1b7f58d) and testing some bug fixes. 10 | 11 | The project also draws on the work of: 12 | 13 | * _**Achim Kalwa**_ who translated the `versionhelpers.h` header into Pascal. Some of the _IsReallyWindowsXXXXOrGreater_ methods of _TPJOSInfo_ and the _TestWindowsVersion_ routine code are based closely on his work. 14 | 15 | * _**Brendan Grant**_ for his ideas presented in the 2007 Code Project article "[Determining the specific edition of Windows for now and in the future](https://bit.ly/1mDKTu3)". 16 | 17 | * _**Kendall Sullivan**_ for the code on which _TPJComputerInfo.IsAdmin_ is based. The code was published in his Embarcadero article "How to detect if the current user is logged in administrator" _(link broken)_. 18 | 19 | * _**norgepaul**_ for the code on which _TPJComputerInfo.IsUACActive_ is based. See his answer to the Stack Overflow question "[Delphi Executing command line command](https://tinyurl.com/avlztmg)". 20 | 21 | * _**Pavel Hruška**_ for the C# code on which _TPJOSInfo.DecodedDigitalProductIDWin8AndUp_ is based. This code is [MIT licensed](https://github.com/mrpeardotnet/WinProdKeyFinder/blob/master/LICENSE) and is copyright (c) 2020 Pavel Hruška. It was taken from [`KeyDecoder.cs`](https://github.com/mrpeardotnet/WinProdKeyFinder/blob/master/WinProdKeyFind/KeyDecoder.cs) from the [mrpeardotnet/WinProdKeyFinder](https://github.com/mrpeardotnet/WinProdKeyFinder) project on GitHub. 22 | 23 | * _**Richard MacCutchan**_ for the C++ code on which _TPJOSInfo.DecodedDigitalProductIDWin7AndDown_ is based. The code was posted on 24 | CodeProject by _enhzflep_ as Solution 4 at to the question ["How to get productId in windows 7 64 bit"](https://tinyurl.com/3n7fbt3h). 25 | 26 | * _**Strive Sun**_ for the C code presented in his answer to the Stack Overflow post ["Win32 API to get Machine UUID"](https://tinyurl.com/cvbx792t). A Pascal translation of some of this code was used as a basis for the portions of the _TPJBiosInfo_ class. 27 | -------------------------------------------------------------------------------- /Docs/Documentation.URL: -------------------------------------------------------------------------------- 1 | [InternetShortcut] 2 | URL=https://delphidabbler.com/url/sysinfo-docs 3 | -------------------------------------------------------------------------------- /Docs/MPL-2.0.txt: -------------------------------------------------------------------------------- 1 | Mozilla Public License Version 2.0 2 | ================================== 3 | 4 | 1. Definitions 5 | -------------- 6 | 7 | 1.1. "Contributor" 8 | means each individual or legal entity that creates, contributes to 9 | the creation of, or owns Covered Software. 10 | 11 | 1.2. "Contributor Version" 12 | means the combination of the Contributions of others (if any) used 13 | by a Contributor and that particular Contributor's Contribution. 14 | 15 | 1.3. "Contribution" 16 | means Covered Software of a particular Contributor. 17 | 18 | 1.4. "Covered Software" 19 | means Source Code Form to which the initial Contributor has attached 20 | the notice in Exhibit A, the Executable Form of such Source Code 21 | Form, and Modifications of such Source Code Form, in each case 22 | including portions thereof. 23 | 24 | 1.5. "Incompatible With Secondary Licenses" 25 | means 26 | 27 | (a) that the initial Contributor has attached the notice described 28 | in Exhibit B to the Covered Software; or 29 | 30 | (b) that the Covered Software was made available under the terms of 31 | version 1.1 or earlier of the License, but not also under the 32 | terms of a Secondary License. 33 | 34 | 1.6. "Executable Form" 35 | means any form of the work other than Source Code Form. 36 | 37 | 1.7. "Larger Work" 38 | means a work that combines Covered Software with other material, in 39 | a separate file or files, that is not Covered Software. 40 | 41 | 1.8. "License" 42 | means this document. 43 | 44 | 1.9. "Licensable" 45 | means having the right to grant, to the maximum extent possible, 46 | whether at the time of the initial grant or subsequently, any and 47 | all of the rights conveyed by this License. 48 | 49 | 1.10. "Modifications" 50 | means any of the following: 51 | 52 | (a) any file in Source Code Form that results from an addition to, 53 | deletion from, or modification of the contents of Covered 54 | Software; or 55 | 56 | (b) any new file in Source Code Form that contains any Covered 57 | Software. 58 | 59 | 1.11. "Patent Claims" of a Contributor 60 | means any patent claim(s), including without limitation, method, 61 | process, and apparatus claims, in any patent Licensable by such 62 | Contributor that would be infringed, but for the grant of the 63 | License, by the making, using, selling, offering for sale, having 64 | made, import, or transfer of either its Contributions or its 65 | Contributor Version. 66 | 67 | 1.12. "Secondary License" 68 | means either the GNU General Public License, Version 2.0, the GNU 69 | Lesser General Public License, Version 2.1, the GNU Affero General 70 | Public License, Version 3.0, or any later versions of those 71 | licenses. 72 | 73 | 1.13. "Source Code Form" 74 | means the form of the work preferred for making modifications. 75 | 76 | 1.14. "You" (or "Your") 77 | means an individual or a legal entity exercising rights under this 78 | License. For legal entities, "You" includes any entity that 79 | controls, is controlled by, or is under common control with You. For 80 | purposes of this definition, "control" means (a) the power, direct 81 | or indirect, to cause the direction or management of such entity, 82 | whether by contract or otherwise, or (b) ownership of more than 83 | fifty percent (50%) of the outstanding shares or beneficial 84 | ownership of such entity. 85 | 86 | 2. License Grants and Conditions 87 | -------------------------------- 88 | 89 | 2.1. Grants 90 | 91 | Each Contributor hereby grants You a world-wide, royalty-free, 92 | non-exclusive license: 93 | 94 | (a) under intellectual property rights (other than patent or trademark) 95 | Licensable by such Contributor to use, reproduce, make available, 96 | modify, display, perform, distribute, and otherwise exploit its 97 | Contributions, either on an unmodified basis, with Modifications, or 98 | as part of a Larger Work; and 99 | 100 | (b) under Patent Claims of such Contributor to make, use, sell, offer 101 | for sale, have made, import, and otherwise transfer either its 102 | Contributions or its Contributor Version. 103 | 104 | 2.2. Effective Date 105 | 106 | The licenses granted in Section 2.1 with respect to any Contribution 107 | become effective for each Contribution on the date the Contributor first 108 | distributes such Contribution. 109 | 110 | 2.3. Limitations on Grant Scope 111 | 112 | The licenses granted in this Section 2 are the only rights granted under 113 | this License. No additional rights or licenses will be implied from the 114 | distribution or licensing of Covered Software under this License. 115 | Notwithstanding Section 2.1(b) above, no patent license is granted by a 116 | Contributor: 117 | 118 | (a) for any code that a Contributor has removed from Covered Software; 119 | or 120 | 121 | (b) for infringements caused by: (i) Your and any other third party's 122 | modifications of Covered Software, or (ii) the combination of its 123 | Contributions with other software (except as part of its Contributor 124 | Version); or 125 | 126 | (c) under Patent Claims infringed by Covered Software in the absence of 127 | its Contributions. 128 | 129 | This License does not grant any rights in the trademarks, service marks, 130 | or logos of any Contributor (except as may be necessary to comply with 131 | the notice requirements in Section 3.4). 132 | 133 | 2.4. Subsequent Licenses 134 | 135 | No Contributor makes additional grants as a result of Your choice to 136 | distribute the Covered Software under a subsequent version of this 137 | License (see Section 10.2) or under the terms of a Secondary License (if 138 | permitted under the terms of Section 3.3). 139 | 140 | 2.5. Representation 141 | 142 | Each Contributor represents that the Contributor believes its 143 | Contributions are its original creation(s) or it has sufficient rights 144 | to grant the rights to its Contributions conveyed by this License. 145 | 146 | 2.6. Fair Use 147 | 148 | This License is not intended to limit any rights You have under 149 | applicable copyright doctrines of fair use, fair dealing, or other 150 | equivalents. 151 | 152 | 2.7. Conditions 153 | 154 | Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted 155 | in Section 2.1. 156 | 157 | 3. Responsibilities 158 | ------------------- 159 | 160 | 3.1. Distribution of Source Form 161 | 162 | All distribution of Covered Software in Source Code Form, including any 163 | Modifications that You create or to which You contribute, must be under 164 | the terms of this License. You must inform recipients that the Source 165 | Code Form of the Covered Software is governed by the terms of this 166 | License, and how they can obtain a copy of this License. You may not 167 | attempt to alter or restrict the recipients' rights in the Source Code 168 | Form. 169 | 170 | 3.2. Distribution of Executable Form 171 | 172 | If You distribute Covered Software in Executable Form then: 173 | 174 | (a) such Covered Software must also be made available in Source Code 175 | Form, as described in Section 3.1, and You must inform recipients of 176 | the Executable Form how they can obtain a copy of such Source Code 177 | Form by reasonable means in a timely manner, at a charge no more 178 | than the cost of distribution to the recipient; and 179 | 180 | (b) You may distribute such Executable Form under the terms of this 181 | License, or sublicense it under different terms, provided that the 182 | license for the Executable Form does not attempt to limit or alter 183 | the recipients' rights in the Source Code Form under this License. 184 | 185 | 3.3. Distribution of a Larger Work 186 | 187 | You may create and distribute a Larger Work under terms of Your choice, 188 | provided that You also comply with the requirements of this License for 189 | the Covered Software. If the Larger Work is a combination of Covered 190 | Software with a work governed by one or more Secondary Licenses, and the 191 | Covered Software is not Incompatible With Secondary Licenses, this 192 | License permits You to additionally distribute such Covered Software 193 | under the terms of such Secondary License(s), so that the recipient of 194 | the Larger Work may, at their option, further distribute the Covered 195 | Software under the terms of either this License or such Secondary 196 | License(s). 197 | 198 | 3.4. Notices 199 | 200 | You may not remove or alter the substance of any license notices 201 | (including copyright notices, patent notices, disclaimers of warranty, 202 | or limitations of liability) contained within the Source Code Form of 203 | the Covered Software, except that You may alter any license notices to 204 | the extent required to remedy known factual inaccuracies. 205 | 206 | 3.5. Application of Additional Terms 207 | 208 | You may choose to offer, and to charge a fee for, warranty, support, 209 | indemnity or liability obligations to one or more recipients of Covered 210 | Software. However, You may do so only on Your own behalf, and not on 211 | behalf of any Contributor. You must make it absolutely clear that any 212 | such warranty, support, indemnity, or liability obligation is offered by 213 | You alone, and You hereby agree to indemnify every Contributor for any 214 | liability incurred by such Contributor as a result of warranty, support, 215 | indemnity or liability terms You offer. You may include additional 216 | disclaimers of warranty and limitations of liability specific to any 217 | jurisdiction. 218 | 219 | 4. Inability to Comply Due to Statute or Regulation 220 | --------------------------------------------------- 221 | 222 | If it is impossible for You to comply with any of the terms of this 223 | License with respect to some or all of the Covered Software due to 224 | statute, judicial order, or regulation then You must: (a) comply with 225 | the terms of this License to the maximum extent possible; and (b) 226 | describe the limitations and the code they affect. Such description must 227 | be placed in a text file included with all distributions of the Covered 228 | Software under this License. Except to the extent prohibited by statute 229 | or regulation, such description must be sufficiently detailed for a 230 | recipient of ordinary skill to be able to understand it. 231 | 232 | 5. Termination 233 | -------------- 234 | 235 | 5.1. The rights granted under this License will terminate automatically 236 | if You fail to comply with any of its terms. However, if You become 237 | compliant, then the rights granted under this License from a particular 238 | Contributor are reinstated (a) provisionally, unless and until such 239 | Contributor explicitly and finally terminates Your grants, and (b) on an 240 | ongoing basis, if such Contributor fails to notify You of the 241 | non-compliance by some reasonable means prior to 60 days after You have 242 | come back into compliance. Moreover, Your grants from a particular 243 | Contributor are reinstated on an ongoing basis if such Contributor 244 | notifies You of the non-compliance by some reasonable means, this is the 245 | first time You have received notice of non-compliance with this License 246 | from such Contributor, and You become compliant prior to 30 days after 247 | Your receipt of the notice. 248 | 249 | 5.2. If You initiate litigation against any entity by asserting a patent 250 | infringement claim (excluding declaratory judgment actions, 251 | counter-claims, and cross-claims) alleging that a Contributor Version 252 | directly or indirectly infringes any patent, then the rights granted to 253 | You by any and all Contributors for the Covered Software under Section 254 | 2.1 of this License shall terminate. 255 | 256 | 5.3. In the event of termination under Sections 5.1 or 5.2 above, all 257 | end user license agreements (excluding distributors and resellers) which 258 | have been validly granted by You or Your distributors under this License 259 | prior to termination shall survive termination. 260 | 261 | ************************************************************************ 262 | * * 263 | * 6. Disclaimer of Warranty * 264 | * ------------------------- * 265 | * * 266 | * Covered Software is provided under this License on an "as is" * 267 | * basis, without warranty of any kind, either expressed, implied, or * 268 | * statutory, including, without limitation, warranties that the * 269 | * Covered Software is free of defects, merchantable, fit for a * 270 | * particular purpose or non-infringing. The entire risk as to the * 271 | * quality and performance of the Covered Software is with You. * 272 | * Should any Covered Software prove defective in any respect, You * 273 | * (not any Contributor) assume the cost of any necessary servicing, * 274 | * repair, or correction. This disclaimer of warranty constitutes an * 275 | * essential part of this License. No use of any Covered Software is * 276 | * authorized under this License except under this disclaimer. * 277 | * * 278 | ************************************************************************ 279 | 280 | ************************************************************************ 281 | * * 282 | * 7. Limitation of Liability * 283 | * -------------------------- * 284 | * * 285 | * Under no circumstances and under no legal theory, whether tort * 286 | * (including negligence), contract, or otherwise, shall any * 287 | * Contributor, or anyone who distributes Covered Software as * 288 | * permitted above, be liable to You for any direct, indirect, * 289 | * special, incidental, or consequential damages of any character * 290 | * including, without limitation, damages for lost profits, loss of * 291 | * goodwill, work stoppage, computer failure or malfunction, or any * 292 | * and all other commercial damages or losses, even if such party * 293 | * shall have been informed of the possibility of such damages. This * 294 | * limitation of liability shall not apply to liability for death or * 295 | * personal injury resulting from such party's negligence to the * 296 | * extent applicable law prohibits such limitation. Some * 297 | * jurisdictions do not allow the exclusion or limitation of * 298 | * incidental or consequential damages, so this exclusion and * 299 | * limitation may not apply to You. * 300 | * * 301 | ************************************************************************ 302 | 303 | 8. Litigation 304 | ------------- 305 | 306 | Any litigation relating to this License may be brought only in the 307 | courts of a jurisdiction where the defendant maintains its principal 308 | place of business and such litigation shall be governed by laws of that 309 | jurisdiction, without reference to its conflict-of-law provisions. 310 | Nothing in this Section shall prevent a party's ability to bring 311 | cross-claims or counter-claims. 312 | 313 | 9. Miscellaneous 314 | ---------------- 315 | 316 | This License represents the complete agreement concerning the subject 317 | matter hereof. If any provision of this License is held to be 318 | unenforceable, such provision shall be reformed only to the extent 319 | necessary to make it enforceable. Any law or regulation which provides 320 | that the language of a contract shall be construed against the drafter 321 | shall not be used to construe this License against a Contributor. 322 | 323 | 10. Versions of the License 324 | --------------------------- 325 | 326 | 10.1. New Versions 327 | 328 | Mozilla Foundation is the license steward. Except as provided in Section 329 | 10.3, no one other than the license steward has the right to modify or 330 | publish new versions of this License. Each version will be given a 331 | distinguishing version number. 332 | 333 | 10.2. Effect of New Versions 334 | 335 | You may distribute the Covered Software under the terms of the version 336 | of the License under which You originally received the Covered Software, 337 | or under the terms of any subsequent version published by the license 338 | steward. 339 | 340 | 10.3. Modified Versions 341 | 342 | If you create software not governed by this License, and you want to 343 | create a new license for such software, you may create and use a 344 | modified version of this License if you rename the license and remove 345 | any references to the name of the license steward (except to note that 346 | such modified license differs from this License). 347 | 348 | 10.4. Distributing Source Code Form that is Incompatible With Secondary 349 | Licenses 350 | 351 | If You choose to distribute Source Code Form that is Incompatible With 352 | Secondary Licenses under the terms of this version of the License, the 353 | notice described in Exhibit B of this License must be attached. 354 | 355 | Exhibit A - Source Code Form License Notice 356 | ------------------------------------------- 357 | 358 | This Source Code Form is subject to the terms of the Mozilla Public 359 | License, v. 2.0. If a copy of the MPL was not distributed with this 360 | file, You can obtain one at http://mozilla.org/MPL/2.0/. 361 | 362 | If it is not possible or desirable to put the notice in a particular 363 | file, then You may include the notice in a location (such as a LICENSE 364 | file in a relevant directory) where a recipient would be likely to look 365 | for such a notice. 366 | 367 | You may add additional accurate notices of copyright ownership. 368 | 369 | Exhibit B - "Incompatible With Secondary Licenses" Notice 370 | --------------------------------------------------------- 371 | 372 | This Source Code Form is "Incompatible With Secondary Licenses", as 373 | defined by the Mozilla Public License, v. 2.0. -------------------------------------------------------------------------------- /Docs/PreSVNHistory.txt: -------------------------------------------------------------------------------- 1 | ================================================================================ 2 | 3 | System Information Unit: Historical update information from v1.0 to v3.1 4 | 5 | ================================================================================ 6 | 7 | This file records known changes to files in the System Information Unit from 8 | v1.0 to and v3.1. before the project was placed was placed under version control 9 | with Subversion. 10 | 11 | There are two sections: 12 | 13 | 1: Releases: Lists all the releases of the project and notes which files were 14 | added, updated or deleted in each release. 15 | 16 | 2: Files: Lists all source code and development tools and provides details of 17 | changes to these files. 18 | 19 | 20 | ================================================================================ 21 | 1: RELEASES 22 | ================================================================================ 23 | 24 | This section lists all releases of the project from the first version (1.0) to 25 | release 3.1. For each release the following is noted: 26 | 27 | + Version and date 28 | + List of new, updated and deleted files. 29 | 30 | For details of changes to each release see ChangeLog.txt 31 | 32 | -------------------------------------------------------------------------------- 33 | v1.0 - 10 Nov 2001 34 | -------------------------------------------------------------------------------- 35 | New - PJSysInfo.pas 1.0 36 | New - PJSysInfo.dcr 1.0 37 | New - Help\PJSysInfo.hap 10 Nov 2001 38 | New - Help\PJSysInfo.hpj 1.0 39 | 40 | -------------------------------------------------------------------------------- 41 | v1.1 - 25 Nov 2001 42 | -------------------------------------------------------------------------------- 43 | Updated - PJSysInfo.pas 1.1 44 | Updated - Help\PJSysInfo.hap 25 Nov 2001 45 | Updated - Help\PJSysInfo.hpj 1.1 46 | 47 | -------------------------------------------------------------------------------- 48 | v1.2 - 30 Jun 2003 49 | -------------------------------------------------------------------------------- 50 | Updated - PJSysInfo.pas 1.2 51 | Updated - Help\PJSysInfo.hap 30 Jun 2003 52 | New - Demo\SysInfoDemo.dpr 1.0 53 | New - Demo\FmDemo.pas 1.0 54 | 55 | -------------------------------------------------------------------------------- 56 | v2.0 - 13 Nov 2005 57 | -------------------------------------------------------------------------------- 58 | Updated - PJSysInfo.pas 2.0 59 | Updated - Help\PJSysInfo.hpj 1.2 60 | Updated - Help\PJSysInfo.hap 13 Nov 2005 61 | New - Help\PJSysInfo.als 13 Nov 2005 62 | Updated - Demo\FmDemo.pas 2.0 63 | 64 | -------------------------------------------------------------------------------- 65 | v2.0.1 - 07 Jan 2006 66 | -------------------------------------------------------------------------------- 67 | Updated - PJSysInfo.pas 2.0.1 68 | 69 | -------------------------------------------------------------------------------- 70 | v2.1 - 15 Oct 2006 71 | -------------------------------------------------------------------------------- 72 | Updated - PJSysInfo.pas 2.1 73 | Updated - Help\PJSysInfo.hpj 1.3 74 | Updated - Help\PJSysInfo.hap 15 Oct 2006 75 | Updated - Help\PJSysInfo.als 15 Oct 2006 76 | 77 | -------------------------------------------------------------------------------- 78 | v3.0 - 15 Apr 2008 79 | -------------------------------------------------------------------------------- 80 | Updated - PJSysInfo.pas 3.0 81 | Updated - Help\PJSysInfo.als 15 Apr 2008 82 | Updated - Help\PJSysInfo.hap 14 Apr 2008 83 | Updated - Help\PJSysInfo.hpj 1.4 84 | Updated - Demo\SysInfoDemo.dpr 1.1 85 | Updated - Demo\FmDemo.pas 2.1 86 | 87 | -------------------------------------------------------------------------------- 88 | v3.1 - 13 Apr 2009 89 | -------------------------------------------------------------------------------- 90 | Updated - PJSysInfo.pas 3.1 91 | Updated - Help\PJSysInfo.als 13 Apr 2009 92 | Updated - Help\PJSysInfo.hap 13 Apr 2009 93 | Updated - Help\PJSysInfo.hpj 1.5 94 | Updated - Demo\FmDemo.pas 2.2 95 | 96 | 97 | ================================================================================ 98 | 2: FILES 99 | ================================================================================ 100 | 101 | This section lists all files for which an update history is known between v1 and 102 | and v3.1, inclusive. 103 | 104 | -------------------------------------------------------------------------------- 105 | Demo\DelphiDabbler.ico 106 | -------------------------------------------------------------------------------- 107 | 10 Sep 2003 - Icon created. 108 | 04 Jul 2009 - IMPORTED TO SVN. 109 | 110 | -------------------------------------------------------------------------------- 111 | Demo\FmDemo.pas/.dfm 112 | -------------------------------------------------------------------------------- 113 | v1.0 of 30 Jun 2003 - Original version. 114 | v2.0 of 13 Nov 2005 - Rewrote to use several tabs to demonstrate component, 115 | static classes, functions and global variables. 116 | v2.1 of 15 Apr 2008 - Removed demo tabs for TPJSysInfo and SIGetXXX routines. 117 | - Removed TPJSysInfo component. 118 | - Added demo lines for new static class methods and global 119 | variables added in PJSysInfo v3.0. 120 | v2.2 of 13 Apr 2009 - Added demo lines and updated enumeration descriptions 121 | for new static class methods added in PJSysInfo v3.1. 122 | 04 Jul 2009 - IMPORTED TO SVN. 123 | 124 | -------------------------------------------------------------------------------- 125 | Demo\SysInfoDemo.dpr 126 | -------------------------------------------------------------------------------- 127 | v1.0 of 30 Jun 2003 - Original version. 128 | v1.1 of 15 Apr 2008 - Added PJSysInfo unit to project. 129 | 04 Jul 2009 - IMPORTED TO SVN. 130 | 131 | -------------------------------------------------------------------------------- 132 | DevTools\BuildHelp.bat 133 | -------------------------------------------------------------------------------- 134 | v1.0 of 15 Apr 2008 - Original version. 135 | 04 Jul 2009 - IMPORTED TO SVN. 136 | 137 | -------------------------------------------------------------------------------- 138 | DevTools\Release.bat 139 | -------------------------------------------------------------------------------- 140 | v1.0 of 14 Apr 2008 - Original version. 141 | 04 Jul 2009 - IMPORTED TO SVN. 142 | 143 | -------------------------------------------------------------------------------- 144 | DevTools\Tidy.bat 145 | -------------------------------------------------------------------------------- 146 | v1.0 of 15 Apr 2008 - Original Version 147 | 04 Jul 2009 - IMPORTED TO SVN. 148 | 149 | -------------------------------------------------------------------------------- 150 | Help\PJSysInfo.als 151 | -------------------------------------------------------------------------------- 152 | 13 Nov 2005 - Original ALS keyword file. 153 | 15 Oct 2006 - Regenerated for new topic. 154 | 15 Apr 2008 - Regenerated re changes in .hap file. 155 | 13 Apr 2009 - Regenerated re new topics. 156 | 04 Jul 2009 - IMPORTED TO SVN. 157 | 158 | -------------------------------------------------------------------------------- 159 | Help\PJSysInfo.hap 160 | -------------------------------------------------------------------------------- 161 | 10 Nov 2001 - Help topic file for new project. 162 | 25 Nov 2001 - Added topics for new properties and functions. 163 | 30 Jun 2003 - Updated topics re new supported operating system. 164 | - Fixed errors (keyword errors and malformed bullets). 165 | 13 Nov 2005 - Added topics for new static classes and methods. 166 | - Added topics for new Wins32* variables. 167 | - Flagged TPJSysInfo and SIGet* functions as deprecated. 168 | 15 Oct 2006 - Added topic for new TPJComputerInfo.MACAddress method. 169 | 14 Apr 2008 - Removed topics for deprecated functions and component. 170 | - Added topics for new methods. 171 | - Added copyright notice. 172 | - Added information about conditional compilation of 173 | deprecated code. 174 | 13/04/2009 - Added topics for new methods. 175 | - Updated enumerated types with new values. 176 | - Corrected some typos. 177 | 04 Jul 2009 - IMPORTED TO SVN. 178 | 179 | -------------------------------------------------------------------------------- 180 | Help\PJSysInfo.hpj 181 | -------------------------------------------------------------------------------- 182 | v1.0 of 10 Nov 2001 - Original version. 183 | v1.1 of 30 Jun 2003 - Updated copyright date to 2001-2003. 184 | Changed reference to PJSoft to DelphiDabbler. 185 | v1.2 of 13 Nov 2005 - Updated copyright date to 2001-2005. 186 | v1.3 of 15 Oct 2006 - Updated copyright date to 2001-2006. 187 | v1.4 of 15 Apr 2008 - Updated copyright date to 2001-2008. 188 | v1.5 of 13 Apr 2009 - Updated copyright date to 2001-2009. 189 | 04 Jul 2009 - IMPORTED TO SVN. 190 | 191 | -------------------------------------------------------------------------------- 192 | PJSysInfo.dcr 193 | -------------------------------------------------------------------------------- 194 | 10 Nov 1002 - Created component palette glyph for TPJSysInfo 195 | component. 196 | 04 Jul 2009 - IMPORTED TO SVN. 197 | 198 | -------------------------------------------------------------------------------- 199 | PJSysInfo.pas 200 | -------------------------------------------------------------------------------- 201 | v1.0 of 10 Nov 2001 - Original version. 202 | v1.1 of 25 Nov 2001 - Added functions and component properties to retrieve 203 | program files and common files folders. 204 | v1.2 of 30 Jun 2003 - Updated palette name to "DelphiDabbler" from "PJ 205 | Stuff" in register procedure. 206 | - Added support for Windows 2003 server to OS 207 | detection functions. 208 | - Removed requirement for Registry unit by accessing 209 | registry via Windows API where required. 210 | - Made TOSVersionInfoEx record definition packed. 211 | - GetOSProduct, GetOSProductType & GetOSServicePack 212 | updated according to latest example on MSDN. 213 | - Used resource strings for exception messages. 214 | v2.0 of 13 Nov 2005 - Added new static classes: TPJComputerInfo (provides 215 | information about the host computer), 216 | TPJSystemFolders (gets paths to system folders) and 217 | TPJOSInfo (provides operating system information). 218 | Together these classes duplicate and extend the 219 | features of the TPJSysInfo component. 220 | - Added new features: gettting Windows product ID; 221 | detection of Windows Vista, XP Media Edition and XP 222 | Tablet Edition; detection of WOW64 sub-system; 223 | further operating system detection features. 224 | - Added new global Win32* variables to provide 225 | extended operating system version information in 226 | style of variables from SysUtils unit. These 227 | variables are intialized at start-up. 228 | - Re-implemented TPJSysInfo and SIGet* functions in 229 | terms of new static classes and deleted private 230 | functions that were no longer required as a result. 231 | - Flagged TPJSysInfo and the SIGet* functions as 232 | deprecated - it is now preferred to use the new 233 | static classes. 234 | - Moved declaration of TOSVersionInfoEx type and 235 | VER_NT_* and VER_SUITE_* constants from 236 | implementation to interface to make publically 237 | available. 238 | - Modified way registry is access to use TRegistry 239 | instead of API calls. 240 | - Introduced conditional compilation to make compile 241 | with Delphi 3 to 7. 242 | v2.0.1 of 07 Jan 2006 - Fixed bug in TPJOSInfo.ProductName reported by 243 | Guillermo Fazzolari. 244 | v2.1 of 15 Oct 2006 - Added new TPJComputerInfo.MACAddress method. 245 | v3.0 of 15 Apr 2008 - All deprecated code, including TPJSysInfo component 246 | is now not compiled by default. Defining 247 | PJSYSINFO_COMPILE_DEPRECATED will cause the 248 | deprecated code to be included. 249 | - Updated for Windows Vista and Windows 2008 Server 250 | and extended amount of info available. 251 | - MakeDirName routine replaced by use of 252 | ExcludeTrailingBackslash on Delphis that support 253 | this in SysUtils. 254 | - Added new HaveWin32ProductInfo and Win32ProductInfo 255 | global variables. 256 | - Added new SM_STARTER and SM_SERVERR2 257 | GetSystemMetrics constants and new VER_SUITE_* 258 | flags. 259 | - Added new PRODUCT_* flags provided by Laurent 260 | Pierre. 261 | - Added several flags to support GetSystemInfo API. 262 | - Added method to TPJComputerInfo to provide number of 263 | processors and their architecture, along with new 264 | TPJProcessorArchitecture enumeration. 265 | - Added check for 64 bit processors to 266 | TPJComputerInfo. 267 | - Added new methods to TPJOsInfo: IsMediaCenter, 268 | IsTabletPC and HasPenExtensions. 269 | - Rewrote TPJOSInfo.Edition method. 270 | - Added wide string version of TOSVersionInfoEx along 271 | with pointer types and Windows style types. 272 | v3.1 of 13 Apr 2009 - Added further PROCESSOR_ARCHITECTURE_*, PROCESSOR_* 273 | and PRODUCT_* constants. 274 | - Made default OS data structures use unicode versions 275 | when UNICODE is defined in an attempt to make the 276 | structures compatible with Delphi 2009. 277 | - Changed to use GetNativeSystemInfo API function to 278 | get processor architecture if possible. 279 | - Modified TPJOSInfo to detect Windows 7 and Windows 280 | 2008 Server R2. Also changed a few OS and product 281 | descriptions. 282 | - Modified TPJOSInfo.Edition to add 64bit 283 | qualification to OS edition information for OSs 284 | running on 64 bit systems and using GetProductInfo 285 | API. 286 | - Added BootMode and IsNetworkPresent methods to 287 | TPJCumputerInfo. 288 | - Added TPJSystemFolders.SystemWow64 method. 289 | - Product name of unknown later Windows version now 290 | contains major and minor version numbers. 291 | 04 Jul 2009 - IMPORTED TO SVN. 292 | 293 | -------------------------------------------------------------------------------- 294 | -------------------------------------------------------------------------------- /Docs/SysInfo-SF-ReadMe.txt: -------------------------------------------------------------------------------- 1 | System Information Unit 2 | ----------------------- 3 | 4 | This directory contains zip files containing System Information Unit releases 5 | from the present release back to v3.2.1. 6 | 7 | The zip files are all of the form dd-sysinfo-x.x.x.zip where x.x.x is the 8 | version number of the release. 9 | 10 | Unless you have good reasons not to, you should always download the latest 11 | version. -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # System Information Unit 2 | 3 | ## Contents 4 | 5 | * [Description](#description) 6 | * [Installation](#installation) 7 | * [Documentation](#documentation) 8 | * [Demo Projects](#demo-projects) 9 | * [Update History](#update-history) 10 | * [Acknowledgements](#acknowledgements) 11 | * [License](#license) 12 | * [Bugs and Feature Requests](#bugs-and-feature-requests) 13 | * [About the Author](#about-the-author) 14 | 15 | This document applies to _System Information Unit_ v5.25.0 and later. 16 | 17 | ## Description 18 | 19 | This unit contains a group of classes and some global variables that provide information about the user's computer system and operating system. Some useful constants and type definitions are also included. The classes are: 20 | 21 | * _TPJComputerInfo_ – static class that provides information about the host computer and the current user. 22 | * _TPJSystemFolders_ – static class that gets the full path to certain system folders. 23 | * _TPJOSInfo_ – static class that supplies information about the operating system. 24 | * _TPJBiosInfo_ - class that provides information about the computer's BIOS. 25 | 26 | In addition, the unit extends and enhances the OS version information provided by the `SysUtils` unit's _Win32xxx_ variables (such as _Win32Platform_) by defining further _Win32xxx_ variables that store the extended operating system information available on later OSs. 27 | 28 | ### Effect of changes to the Windows API 29 | 30 | With the release of Windows 8.1, Microsoft made a controversial decision to deprecate the _GetVersion_ API functions. These functions have always been used by the _System Information Unit_ to retrieve OS version formation. A new method of checking the operating system version was recommended, which was to use the _VerifyVersionInfo_ API. Unbelievably, this API itself became deprecated in Windows 10, but no viable alternative was introduced. In fact, the Windows 10 SDK still uses the newly deprecated API! 31 | 32 | If the old _GetVersion_ approach is used then Windows 8.1 represents itself as Windows 8, unless the host program has a [special manifest](https://docs.microsoft.com/en-gb/windows/win32/sysinfo/targeting-your-application-at-windows-8-1). Using the _VerifyVersionInfo_ API gets round that problem and Windows 8.1 reports itself as the correct version, with or without the manifest. 33 | 34 | For this reason, release 5.0 of the _System Information Unit_ was revised to use the _VerifyVersionInfo_ API for Windows 8.1 and later while retaining the _GetVersion_ API for Windows 8 and earlier. 35 | 36 | With Windows 10, the _VerifyVersionInfo_ API only reports Windows 10 correctly if the host program is [manifested](https://docs.microsoft.com/en-gb/windows/win32/sysinfo/targeting-your-application-at-windows-8-1) correctly. If there is no suitable manifest then Windows 10 reports itself as Windows 8, regardless of the API used. Believe it or not, this behaviour is as designed by Microsoft. 37 | 38 | Unfortunately, the decision made in release 5.0 to apply _VerifyVersionInfo_ only to Windows 8.1 and later resulted in un-manifested applications running on Windows 10 reporting Windows 7 instead of Windows 8 as documented by Microsoft. To fix this problem the _VerifyVersionInfo_ API is now also used when running on Windows 8. 39 | 40 | Apart from being more cumbersome and slower, the _VerifyVersionInfo_ API approach differs from the old approach in an important respect. When a program is run in compatibility mode the old _GetVersion_ API functions would be fooled (or"spoofed") by Windows into reporting the version of the operating system emulated by the compatibility mode (more or less!). This is the way the unit has always behaved in the past. The new approach used for Windows 8.1 (introduced in v5.0 of this unit) always returns information about the true operating system, regardless of any active compatibility mode. As noted above, when adding support for Windows 10 (in version 5.1) the use of _VerifyVersionInfo_ was extended to Windows 8. As a consequence Windows 8, 8.1 and 10 cannot be spoofed. This is a change to the behaviour of v5.0 for Windows 8, meaning some code that depended on being able to spoof Windows 8 may no longer work. 41 | 42 | To make things easier for users of Windows 2000 and later (i.e. just about everyone) a bunch of interrogation functions that can't be spoofed have been added to _TPJOSInfo_. You can also find out if OS spoofing is enabled for the host operating system by examining the _CanSpoof_ method of _TPJOSInfo_. 43 | 44 | In summary, we have several inconsistencies in _TPJOSInfo_, all because of some incomprehensible decisions made by Microsoft. They are: 45 | 46 | * For OSs up to and including Windows 7 SP 1, the reported operating system can be "spoofed" by setting the host program's compatibility mode. The exception is that the _TPJOSInfo.IsReallyWindowsXXXOrGreater_ methods for Windows 2000 to 8.1 will detect the actual underlying operating system version. 47 | 48 | * For Windows 8 and 8.1 the reported operating system cannot be spoofed using compatibility modes. Furthermore, the presence or absence of a suitable manifest file doesn't affect the returned values. This also applies to the relevant _TPJOSInfo.IsReallyWindowsXXXOrGreater_ methods. 49 | 50 | * For Windows 10 and 11, the reported operating system cannot be spoofed, regardless of whether or not a suitable manifest is compiled into resources. However, in the absence of such a manifest, the version is _always_ reported as Windows 8! This also affects the _TPJOSInfo.IsReallyWindows10OrGreater_ method, meaning that it's not so well named any more! 51 | 52 | After exploring and testing a lot of options this really is the best solution I can find. **Thanks a bundle Microsoft!** 53 | 54 | To add insult to injury, when Microsoft released the Windows 10 "November Update" (a.k.a TH2 a.k.a. Version 1511) they bumped the OS's build number but didn't update the service pack version information. Therefore existing code didn't report the update other than via the change in build number. I didn't want to break the existing _TPJOSInfo.ServicePack_ method by pretending that TH2 was really a service pack, so I added a new _ServicePackEx_ method to report any significant updates that don't declare themselves as service packs. Ho hum! 55 | 56 | Unbelievably Windows 11 still declares itself as v10.0, making it indistinguishable from Windows 10. In fact the release of Windows 11 was only distinguished by a change in revision to a certain build number. _TPJOSInfo_ looks out for that change and reports Windows 11 correctly. They really don't make it easy do they? 57 | 58 | Sorry that this is all so complicated - but it's ***complicated***!! And, IMHO, deeply stupid. 59 | 60 | ### Debug Mode 61 | 62 | To help with debugging, developers can define the `DEBUG` symbol. Range checking is forced on when `DEBUG` is defined. 63 | 64 | Normally, the _VerifyVersionInfo_ API is used only when detecting Windows 8 and later. To enable code using this API to be tested on machines running Windows Vista or Windows 7, developers can temporarily define the `DEBUG_NEW_API` symbol. This causes the _VerifyVersionInfo_ API to be used for detection of Windows Vista and Windows 7. `DEBUG_NEW_API` is less useful than it was when Windows 8 was new: the symbol may be removed from future relesses. 65 | 66 | ### Deleted Code 67 | 68 | Version 2 and earlier of the unit provided the _TPJSysInfo_ component and various _SIGetxxx_ functions. As of v3.0 these were deprecated and finally removed at v4.0. 69 | 70 | ### Compatibility 71 | 72 | This unit is designed for compilation with the 32 bit and 64 bit Windows Delphi compilers. The latest version has been tested with Delphi XE, Delphi 11.0 Alexandria and Delphi 12 Athens only. An attempt has been made to retain compatibility back to Delphi 4, but this has not been tested for some time, so it's not guaranteed. 73 | 74 | Compilation on old Delphi versions that do not support setting registry access flags via _TRegistry_ is not recommended since parts of the code may not work correctly on 64 bit Windows. 75 | 76 | The unit is not compatible with .NET. 77 | 78 | The unit _should_ operate correctly on the following platforms: 79 | 80 | * Windows 95 to Me 81 | * All 32 bit NT platform operating systems. 82 | * Windows 64 bit, either as part of a 32 bit or 64 bit process. 83 | 84 | While every effort is made to keep the code as compatible with all OSs as possible, I'm only able to test on my one and only Windows OS: currently Windows 11. 85 | 86 | The code is not suitable for non-Windows operating systems since it depends on the Windows API. 87 | 88 | ## Installation 89 | 90 | The _System Information Unit_ and demo programs are supplied in a zip file. Before installing you need to extract all the files, preserving the directory structure. The following files will be extracted: 91 | 92 | * **`PJSysInfo.pas`** – Source code of the classes, global variables, constants and type definitions. 93 | * `README.md` – This read-me file. 94 | * `CHANGELOG.md` – The unit's change log. 95 | * `MPL-2.0.txt` – Mozilla Public Licence v2.0. 96 | * `Documentation.URL` – Short-cut to online documentation. 97 | 98 | In addition to the above files you will find the source code of two demo projects and their read-me file in the `Demos` directory. 99 | 100 | There are four possible ways to use the unit. 101 | 102 | 1. The simplest way is to add `PJSysInfo.pas` to your projects as you need it. 103 | 2. To make the unit easier to re-use you can either copy it to a folder on your Delphi search path, or add the folder where you extracted the unit to the search path. You then simply use the unit as required without needing to add it to your project. 104 | 3. For maximum portability you can add the unit to a Delphi package. 105 | 4. If you use Git you can added the [`ddablib/sysinfo`](https://github.com/ddablib/sysinfo) GitHub repository as a Git submodule and add it to your project. Obviously, it's safer if you fork the repo and use your copy, just in case `ddablib/sysinfo` ever goes away. 106 | 107 | ## Documentation 108 | 109 | The _System Information Unit_ is fully [documented online](https://delphidabbler.com/url/sysinfo-docs). 110 | 111 | ## Demo Projects 112 | 113 | Two demo projects are included in the download in the `Demos\VCL` and the `Demos\FMX` directories. The former compiles to a VCL application using Delphi XE (and possibly even Delphi 4) or later while the latter uses the FireMonkey 2 framework and requires Delphi XE3 as a minimum. Both projects can be compiled to either Windows 32 bit or 64 bit targets. 114 | 115 | Each project contains a tab set where each tab displays the information from one of the classes or the global variables. 116 | 117 | ## Update History 118 | 119 | A complete change log is provided in [`CHANGELOG.md`](https://github.com/ddablib/sysinfo/blob/main/CHANGELOG.md) that is included in the download. 120 | 121 | ## Acknowledgements 122 | 123 | Information from numerous websites has been used while developing this code. Several individuals have also suggested solutions or contributed code. 124 | 125 | Full details are provided in the file [`Acknowledgements.md`](https://github.com/ddablib/sysinfo/blob/main/Docs/Acknowledgements.md) in the `./Docs` subdirectory of the [`ddablib/sysinfo`](https://github.com/ddablib/sysinfo) GitHub repository. 126 | 127 | ## License 128 | 129 | The _System Information Unit_ is copyright © 2001-2025 [Peter D Johnson](https://gravatar.com/delphidabbler) and is released under the terms of the [Mozilla Public License, v2.0](https://www.mozilla.org/MPL/2.0/). 130 | 131 | ## Bugs and Feature Requests 132 | 133 | Bugs can be reported or new features requested via the [Issue Tracker](https://github.com/ddablib/sysinfo/issues). A GitHub account is required. 134 | 135 | ## About the Author 136 | 137 | I'm Peter Johnson – a hobbyist programmer living in Ceredigion in West Wales, UK, writing mainly in Delphi. My programs and other library code are available from: [https://delphidabbler.com/](https://delphidabbler.com/). 138 | 139 | This document is copyright © 2005-2025, [Peter D Johnson](https://gravatar.com/delphidabbler). 140 | --------------------------------------------------------------------------------