{"id":1641,"date":"2009-08-18T02:43:47","date_gmt":"2009-08-18T10:43:47","guid":{"rendered":"http:\/\/www.sapien.com\/blog\/?p=1641"},"modified":"2009-08-18T09:38:48","modified_gmt":"2009-08-18T17:38:48","slug":"registry-access-from-32-to-64-bit-and-back","status":"publish","type":"post","link":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/","title":{"rendered":"Registry access from 32 to 64 bit and back"},"content":{"rendered":"<p>Just recently, I received an email asking how you can access the 64 bit registry from a 32 bit script, or vice versa. The task the individual was facing was to come up with a way to verify installed applications via checking the corresponding Windows Installer registry entries.<\/p>\n<p>For a C++ programmer with access to the API, that really is not a big issue. From VBScript, using only WshShell.RegRead that is a completely different story. A quick consult with some fellow script experts revealed that the only real way was using WMI and the StdRegProvider. The main complaint I heard though was that this was a rather slow and sluggish way of doing it.<\/p>\n<p>So I decided to pick up the slack and create a new COM component that makes accessing the registry a bit simpler than using WMI, all the while maintaining some of the native API&#8217;s speed.<\/p>\n<pre class=\"code\"><pre class=\"code\"><span style=\"color: blue\">&nbsp;<\/span><\/pre>\n<p><a href=\"http:\/\/11011.net\/software\/vspaste\"><\/a> <a href=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2009\/08\/image.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" style=\"border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px\" height=\"149\" alt=\"image\" src=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2009\/08\/image_thumb.png\" width=\"244\" border=\"0\"><\/a><\/p>\n<p>The new component is available with PrimalScript builds 5.0.615 and higher. It is automatically installed and registered. Please check out the sample file RegistryAccess.vbs in the PrimalScript samples folder.<\/p>\n<p>Additionally, VBScript expert and all-around scripting guru Alex Angelopoulos was nice enough to help me design the interface and test it by providing two more sample scripts that use this control:<\/p>\n<p><strong>EnumerateControlsWithKillBits.vbs:<\/strong><\/p>\n<p><em>Enumerates GUIDs for controls that have been kill-bitted to not run in IE. (Note that these controls CAN still run in HTAs and other local applications). Shows the flags set for the control as a simple number, and &#8211; if the control is installed and it has a common name listed &#8211; shows the control name and the path to the control.<br \/>Elements are separated by commas. This will give odd-looking output in a console window, but is useful for redirection to a file and later opening in Excel.<\/em><\/p>\n<p><strong>AutoAddScriptRunAs.vbs:<\/strong><\/p>\n<p><em>Simplifies running scripts as privileged processes or with alternate<br \/>credentials.&nbsp; For our purposes, a &#8220;script&#8221; is any file type whose extension is in the environment&#8217;s %pathext% variable (except .com\/.exe\/.msc files since they are handled by Windows already), and ALSO files with the .hta extension.<br \/>This script has the following effects when run:<br \/>(1) On pre-Vista systems, the only apparent change will be a &#8220;Run As&#8221; entry on the context menu allowing you to specify alternate credentials for running a script.<br \/>(2) On Vista and newer, the context menu choice will be a localized variant of &#8220;Run as administrator&#8221; and will show an LUA shield icon next to the choice. Selecting this will cause the script host to request elevation at launch.<br \/>(3) On Windows 7 and newer systems, scripts containing the word<br \/>&#8220;admin&#8221; in their names will automatically attempt to run elevated if you double-click them or run them using the Run dialog. Note that the word admin must be a distinct word separated from other alphanumeric characters in the script name. The following are examples of names that will cause automatic elevation requests in HTA files:<br \/>admin.hta, &#8220;admin file.hta&#8221;, admin-test.hta<br \/>the following will NOT cause automatic elevation requests:<br \/>admintools.hta makemeadmin.hta<br \/>Also note that you can choose to right-click and Open the script without elevation explicitly.<\/em><\/p>\n<p><a href=\"http:\/\/www.sapien.com\/download.aspx?file=regsample\" target=\"_blank\">Click here to download the sample files.<\/a><\/p>\n<p>Below is a brief overview of the methods and properties in this new component:<\/p>\n<table cellspacing=\"0\" cellpadding=\"2\" width=\"462\" border=\"1\">\n<tbody>\n<tr>\n<td valign=\"top\" width=\"210\"><strong>Property<\/strong><\/td>\n<td valign=\"top\" width=\"250\"><strong>Description<\/strong><\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">RegistryView<\/td>\n<td valign=\"top\" width=\"250\">Set or returns the current registry view,<br \/>(1 = 32 bit (default), 2 = 64 bit)<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">ErrorCode<\/td>\n<td valign=\"top\" width=\"250\">Returns the error code of the last operation. 0 = no error, positive numbers are Windows error codes, negative numbers are internal error codes.<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">ErrorDescription<\/td>\n<td valign=\"top\" width=\"250\">Returns the description of the last error indicated in the ErrorCode property<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">Handle<\/td>\n<td valign=\"top\" width=\"250\">Returns the actual HKEY handle value of the currently opened key.<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">FullKeyPath<\/td>\n<td valign=\"top\" width=\"250\">Returns the full key path of the currently opened key. Does not operate on remote keys.<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">RootKey<\/td>\n<td valign=\"top\" width=\"250\">Returns the root key (HKLM, HKCR, HKEY_CURRENT_USER etc.) of the currently opened key. Does not operate on remote keys.<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">SubKeyPath<\/td>\n<td valign=\"top\" width=\"250\">Returns the key path of the currently opened key without the root node specifier. Does not operate on remote keys.<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">ReadOnly<\/td>\n<td valign=\"top\" width=\"250\">Sets or returns the content of the read-only flag (default: FALSE), which determines if registry keys are opened with KEY_READ or KEY_ALL_ACCESS<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\"><strong>Methods<\/strong><\/td>\n<td valign=\"top\" width=\"250\"><strong>Description<\/strong><\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">OpenKey(BaseKey,SubKey,bCreate)<\/td>\n<td valign=\"top\" width=\"250\">Opens a registry key or optionally creates it if it does not exist<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">CloseKey()<\/td>\n<td valign=\"top\" width=\"250\">Closes the handle of the currently opened registry key<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">DeleteKey(BaseKey,SubKey)<\/td>\n<td valign=\"top\" width=\"250\">Deletes an existing registry key. No key must be opened at the time<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">DeleteValue(ValueName)<\/td>\n<td valign=\"top\" width=\"250\">Deletes the specified value in the opened key, use &#8220;&#8221; to delete the default value<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">GetValue(ValueName)<\/td>\n<td valign=\"top\" width=\"250\">Returns the content of the specified value, use &#8220;&#8221; to retrieve a key&#8217;s default value<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">GetValueType(ValueName)<\/td>\n<td valign=\"top\" width=\"250\">Returns the type of specified value, use &#8220;&#8221; to retrieve a key&#8217;s default value&#8217;s type<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">GetValueList()<\/td>\n<td valign=\"top\" width=\"250\">Returns an array with the names of the values under the currently opened key. The default value (empty name) is not included in this list<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">GetKeyList()<\/td>\n<td valign=\"top\" width=\"250\">Returns an array with names of the immediate child keys of the currently opened key<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">GetSubKey(Key,bCreate)<\/td>\n<td valign=\"top\" width=\"250\">Returns a new object representing the opened handle of the specified subkey.<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">SetValue(Name,Value,ValueType)<\/td>\n<td valign=\"top\" width=\"250\">Sets the content of the specified value. Use &#8220;&#8221; to set the content of the default value. Non-existent values will be created automatically.<br \/>Supported value types are: REG_SZ, REG_EXPAND_SZ, REG_MULTI_SZ and REG_DWORD<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">SaveKey(FileName)<\/td>\n<td valign=\"top\" width=\"250\">Saves the currently open key as binary data to the specified file. Existing files are overwritten<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">RestoreKey(FileName,bForce)<\/td>\n<td valign=\"top\" width=\"250\">Restores the content of the currently opened key from a binary file previously created with &#8220;SaveKey&#8221;<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">ConnectRegistry(MachineName, BaseKey [,&nbsp; UserID][, Password]<\/td>\n<td valign=\"top\" width=\"250\">Opens a root registry handle of a remote machine. You must have administrative rights on the remote computer.<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">OpenFromHandle(Handle)<\/td>\n<td valign=\"top\" width=\"250\">Opens the registry key as specified by the handle<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">HasSubKey(key)<\/td>\n<td valign=\"top\" width=\"250\">Indicates if the currently opened key has a child key with the specified name<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">HasValue(Name)<\/td>\n<td valign=\"top\" width=\"250\">Indicates if the currently opened key has the specified value<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">IsKey(BaseKey,SubKey)<\/td>\n<td valign=\"top\" width=\"250\">Returns if the provided key exists. This does not depend on the currently opened key. Does not operate on remote keys<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">IsValue(Basekey,SubKey, ValueName)<\/td>\n<td valign=\"top\" width=\"250\">Returns if the specified value exists. This does not depend on the currently opened key. Does not operate on remote keys<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">GotoSubKey(SubKey)<\/td>\n<td valign=\"top\" width=\"250\">Navigates the current key to a child key. Multiple levels can be specified separated by a &#8216;\\&#8217; character. The specified key must exist.<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"210\">GotoParentKey()<\/td>\n<td valign=\"top\" width=\"250\">Navigates to the immediate parent key of the currently opened key<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Unless otherwise noted, functions return vbTrue or vbFalse to indicate success or an error.<\/p>\n<p>For feedback, feature requests or error reports please use our <a href=\"http:\/\/support.sapien.com\/forum\/forum_topics.asp?FID=10\" target=\"_blank\">free tools support forum<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Just recently, I received an email asking how you can access the 64 bit registry from a 32 bit script, or vice versa. The task the individual was facing was to come up with a way to verify installed applications via checking the corresponding Windows Installer registry entries. For a C++ programmer with access to [&hellip;]<\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[283,410,21,24,389,26],"tags":[526,525,61,37,31,36,996],"class_list":["post-1641","post","type-post","status-publish","format-standard","hentry","category-howto","category-primalscript-software-news","category-software-news","category-vbscript","category-vbscript-scripts","category-windows-scripting-news","tag-32-bit","tag-64-bit","tag-com","tag-primalscript","tag-registry","tag-remote","tag-vbscript"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.1 - aioseo.com -->\n\t<meta name=\"description\" content=\"Just recently, I received an email asking how you can access the 64 bit registry from a 32 bit script, or vice versa. The task the individual was facing was to come up with a way to verify installed applications via checking the corresponding Windows Installer registry entries. For a C++ programmer with access to\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Alex Riedel\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.1\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"DEV SAPIEN Blog - Tools for IT Success\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"Registry access from 32 to 64 bit and back - DEV SAPIEN Blog\" \/>\n\t\t<meta property=\"og:description\" content=\"Just recently, I received an email asking how you can access the 64 bit registry from a 32 bit script, or vice versa. The task the individual was facing was to come up with a way to verify installed applications via checking the corresponding Windows Installer registry entries. For a C++ programmer with access to\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2009-08-18T10:43:47+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2009-08-18T17:38:48+00:00\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n\t\t<meta name=\"twitter:title\" content=\"Registry access from 32 to 64 bit and back - DEV SAPIEN Blog\" \/>\n\t\t<meta name=\"twitter:description\" content=\"Just recently, I received an email asking how you can access the 64 bit registry from a 32 bit script, or vice versa. The task the individual was facing was to come up with a way to verify installed applications via checking the corresponding Windows Installer registry entries. For a C++ programmer with access to\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"BlogPosting\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/2009\\\/08\\\/18\\\/registry-access-from-32-to-64-bit-and-back\\\/#blogposting\",\"name\":\"Registry access from 32 to 64 bit and back - DEV SAPIEN Blog\",\"headline\":\"Registry access from 32 to 64 bit and back\",\"author\":{\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/author\\\/alexander-riedel\\\/#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/#organization\"},\"image\":{\"@type\":\"ImageObject\",\"url\":\"http:\\\/\\\/www.sapien.com\\\/blog\\\/wp-content\\\/uploads\\\/2009\\\/08\\\/image_thumb.png\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/2009\\\/08\\\/18\\\/registry-access-from-32-to-64-bit-and-back\\\/#articleImage\"},\"datePublished\":\"2009-08-18T02:43:47-07:00\",\"dateModified\":\"2009-08-18T09:38:48-07:00\",\"inLanguage\":\"en-US\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/2009\\\/08\\\/18\\\/registry-access-from-32-to-64-bit-and-back\\\/#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/2009\\\/08\\\/18\\\/registry-access-from-32-to-64-bit-and-back\\\/#webpage\"},\"articleSection\":\"Howto, PrimalScript, Software News, VBScript, VBScript Scripts, Windows Scripting News, 32 bit, 64 bit, com, PrimalScript, registry, remote, VBScript\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/2009\\\/08\\\/18\\\/registry-access-from-32-to-64-bit-and-back\\\/#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/dev.sapien.com\\\/blog\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/topics\\\/software-news\\\/#listItem\",\"name\":\"Software News\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/topics\\\/software-news\\\/#listItem\",\"position\":2,\"name\":\"Software News\",\"item\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/topics\\\/software-news\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/topics\\\/software-news\\\/primalscript-software-news\\\/#listItem\",\"name\":\"PrimalScript\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/topics\\\/software-news\\\/primalscript-software-news\\\/#listItem\",\"position\":3,\"name\":\"PrimalScript\",\"item\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/topics\\\/software-news\\\/primalscript-software-news\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/2009\\\/08\\\/18\\\/registry-access-from-32-to-64-bit-and-back\\\/#listItem\",\"name\":\"Registry access from 32 to 64 bit and back\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/topics\\\/software-news\\\/#listItem\",\"name\":\"Software News\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/2009\\\/08\\\/18\\\/registry-access-from-32-to-64-bit-and-back\\\/#listItem\",\"position\":4,\"name\":\"Registry access from 32 to 64 bit and back\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/topics\\\/software-news\\\/primalscript-software-news\\\/#listItem\",\"name\":\"PrimalScript\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/#organization\",\"name\":\"DEV SAPIEN Blog\",\"description\":\"Tools for IT Success\",\"url\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/author\\\/alexander-riedel\\\/#author\",\"url\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/author\\\/alexander-riedel\\\/\",\"name\":\"Alex Riedel\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/2009\\\/08\\\/18\\\/registry-access-from-32-to-64-bit-and-back\\\/#webpage\",\"url\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/2009\\\/08\\\/18\\\/registry-access-from-32-to-64-bit-and-back\\\/\",\"name\":\"Registry access from 32 to 64 bit and back - DEV SAPIEN Blog\",\"description\":\"Just recently, I received an email asking how you can access the 64 bit registry from a 32 bit script, or vice versa. The task the individual was facing was to come up with a way to verify installed applications via checking the corresponding Windows Installer registry entries. For a C++ programmer with access to\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/2009\\\/08\\\/18\\\/registry-access-from-32-to-64-bit-and-back\\\/#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/author\\\/alexander-riedel\\\/#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/author\\\/alexander-riedel\\\/#author\"},\"datePublished\":\"2009-08-18T02:43:47-07:00\",\"dateModified\":\"2009-08-18T09:38:48-07:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/\",\"name\":\"DEV SAPIEN Blog\",\"description\":\"Tools for IT Success\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/dev.sapien.com\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Registry access from 32 to 64 bit and back - DEV SAPIEN Blog","description":"Just recently, I received an email asking how you can access the 64 bit registry from a 32 bit script, or vice versa. The task the individual was facing was to come up with a way to verify installed applications via checking the corresponding Windows Installer registry entries. For a C++ programmer with access to","canonical_url":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"BlogPosting","@id":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/#blogposting","name":"Registry access from 32 to 64 bit and back - DEV SAPIEN Blog","headline":"Registry access from 32 to 64 bit and back","author":{"@id":"https:\/\/dev.sapien.com\/blog\/author\/alexander-riedel\/#author"},"publisher":{"@id":"https:\/\/dev.sapien.com\/blog\/#organization"},"image":{"@type":"ImageObject","url":"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2009\/08\/image_thumb.png","@id":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/#articleImage"},"datePublished":"2009-08-18T02:43:47-07:00","dateModified":"2009-08-18T09:38:48-07:00","inLanguage":"en-US","mainEntityOfPage":{"@id":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/#webpage"},"isPartOf":{"@id":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/#webpage"},"articleSection":"Howto, PrimalScript, Software News, VBScript, VBScript Scripts, Windows Scripting News, 32 bit, 64 bit, com, PrimalScript, registry, remote, VBScript"},{"@type":"BreadcrumbList","@id":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/dev.sapien.com\/blog#listItem","position":1,"name":"Home","item":"https:\/\/dev.sapien.com\/blog","nextItem":{"@type":"ListItem","@id":"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/#listItem","name":"Software News"}},{"@type":"ListItem","@id":"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/#listItem","position":2,"name":"Software News","item":"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/","nextItem":{"@type":"ListItem","@id":"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/primalscript-software-news\/#listItem","name":"PrimalScript"},"previousItem":{"@type":"ListItem","@id":"https:\/\/dev.sapien.com\/blog#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/primalscript-software-news\/#listItem","position":3,"name":"PrimalScript","item":"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/primalscript-software-news\/","nextItem":{"@type":"ListItem","@id":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/#listItem","name":"Registry access from 32 to 64 bit and back"},"previousItem":{"@type":"ListItem","@id":"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/#listItem","name":"Software News"}},{"@type":"ListItem","@id":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/#listItem","position":4,"name":"Registry access from 32 to 64 bit and back","previousItem":{"@type":"ListItem","@id":"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/primalscript-software-news\/#listItem","name":"PrimalScript"}}]},{"@type":"Organization","@id":"https:\/\/dev.sapien.com\/blog\/#organization","name":"DEV SAPIEN Blog","description":"Tools for IT Success","url":"https:\/\/dev.sapien.com\/blog\/"},{"@type":"Person","@id":"https:\/\/dev.sapien.com\/blog\/author\/alexander-riedel\/#author","url":"https:\/\/dev.sapien.com\/blog\/author\/alexander-riedel\/","name":"Alex Riedel"},{"@type":"WebPage","@id":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/#webpage","url":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/","name":"Registry access from 32 to 64 bit and back - DEV SAPIEN Blog","description":"Just recently, I received an email asking how you can access the 64 bit registry from a 32 bit script, or vice versa. The task the individual was facing was to come up with a way to verify installed applications via checking the corresponding Windows Installer registry entries. For a C++ programmer with access to","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/dev.sapien.com\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/#breadcrumblist"},"author":{"@id":"https:\/\/dev.sapien.com\/blog\/author\/alexander-riedel\/#author"},"creator":{"@id":"https:\/\/dev.sapien.com\/blog\/author\/alexander-riedel\/#author"},"datePublished":"2009-08-18T02:43:47-07:00","dateModified":"2009-08-18T09:38:48-07:00"},{"@type":"WebSite","@id":"https:\/\/dev.sapien.com\/blog\/#website","url":"https:\/\/dev.sapien.com\/blog\/","name":"DEV SAPIEN Blog","description":"Tools for IT Success","inLanguage":"en-US","publisher":{"@id":"https:\/\/dev.sapien.com\/blog\/#organization"}}]},"og:locale":"en_US","og:site_name":"DEV SAPIEN Blog - Tools for IT Success","og:type":"article","og:title":"Registry access from 32 to 64 bit and back - DEV SAPIEN Blog","og:description":"Just recently, I received an email asking how you can access the 64 bit registry from a 32 bit script, or vice versa. The task the individual was facing was to come up with a way to verify installed applications via checking the corresponding Windows Installer registry entries. For a C++ programmer with access to","og:url":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/","article:published_time":"2009-08-18T10:43:47+00:00","article:modified_time":"2009-08-18T17:38:48+00:00","twitter:card":"summary_large_image","twitter:title":"Registry access from 32 to 64 bit and back - DEV SAPIEN Blog","twitter:description":"Just recently, I received an email asking how you can access the 64 bit registry from a 32 bit script, or vice versa. The task the individual was facing was to come up with a way to verify installed applications via checking the corresponding Windows Installer registry entries. For a C++ programmer with access to"},"aioseo_meta_data":{"post_id":"1641","title":null,"description":null,"keywords":null,"keyphrases":null,"focus_keyword":null,"additional_keywords":null,"truseo_locale":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_custom_url":null,"og_image_custom_fields":null,"og_image_url":null,"og_image_width":null,"og_image_height":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_image_url":null,"twitter_title":null,"twitter_description":null,"schema_type":"default","schema_type_options":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"","isEnabled":true},"graphs":[]},"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"limit_modified_date":false,"ai":null,"breadcrumb_settings":null,"seo_analyzer_scan_date":null,"created":"2026-08-28 14:55:39","updated":"2026-08-28 14:55:39"},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/dev.sapien.com\/blog\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/\" title=\"Software News\">Software News<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/primalscript-software-news\/\" title=\"PrimalScript\">PrimalScript<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tRegistry access from 32 to 64 bit and back\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/dev.sapien.com\/blog"},{"label":"Software News","link":"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/"},{"label":"PrimalScript","link":"https:\/\/dev.sapien.com\/blog\/topics\/software-news\/primalscript-software-news\/"},{"label":"Registry access from 32 to 64 bit and back","link":"https:\/\/dev.sapien.com\/blog\/2009\/08\/18\/registry-access-from-32-to-64-bit-and-back\/"}],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts\/1641","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/comments?post=1641"}],"version-history":[{"count":3,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts\/1641\/revisions"}],"predecessor-version":[{"id":1644,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts\/1641\/revisions\/1644"}],"wp:attachment":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/media?parent=1641"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/categories?post=1641"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/tags?post=1641"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}