Navigation:  Commands and Procedures >

64-bit vs. 32-bit

Previous pageReturn to chapter overviewNext page

Visual Build (the GUI and Console apps and COM object model) is available in 32-bit and 64-bit editions.  The 32-bit edition is compatible with 32-bit editions of Windows, and also 64-bit editions of Windows via the WoW64 subsystem.  The 64-bit edition is a native x64 executable that does not require the WoW64 subsystem and can only be installed on a 64-bit edition of Windows.

 

File System

 

The 32-bit edition of Visual Build is able to call 64-bit executables (and vice versa), but Windows does implement file system redirection from %WINDIR%\System32 to %WINDIR%\SysWOW64 for 32-bit programs.  Use the 64-bit edition of Visual Build, or when using the 32-bit edition use %WINDIR%\Sysnative instead of %WINDIR%\System32 to run 64-bit programs in this folder or to pass this folder to another 32-bit program and prevent redirection (on Windows 2003, first install the Windows hotfix that adds support for Sysnative).  Other options are also available for calling programs in the true 64-bit %WINDIR%\System32 folder from the 32-bit edition of Visual Build:

1.Manually copy executables from %WINDIR%\System32 to another folder (using the 64-bit Explorer.exe or cmd.exe) to call them from Visual Build.
2.Run SUBST S: %WINDIR%\System32 from a 64-bit Command Prompt and then access the folder via S: from Visual Build.
3.Create an NTFS junction point that points to the %WINDIR%\System32 folder. Access the NTFS junction point instead of %WINDIR%\System32.

 

Notes:

To call the 64-bit version of cmd.exe from the 32-bit edition of Visual Build when using the DOSCMD system macro or the Command to run before main command field on the advanced tab of the Run Program and derived actions, create a COMSPEC global macro with a value of %WINDIR%\Sysnative\cmd.exe.
To call the 32-bit version of cmd.exe from the 64-bit edition of Visual Build when using the DOSCMD system macro or the Command to run before main command field on the advanced tab of the Run Program and derived actions, create a COMSPEC global macro with a value of %WINDIR%\SysWOW64\cmd.exe.

 

Registry

 

On 64-bit editions of Windows, some portions of the registry are redirected or reflected for 32-bit applications.  Options for accessing the 64-bit registry view from the 32-bit edition of Visual Build:

1.Use the Access 64-bit registry view option of the Read Registry and Write Registry actions.
2.From script code, call the vbld_ReadRegHKLM64 system script function.
3.Use registry locations that are shared by 32- and 64-bit applications.
4.Call the 64-bit %WINDIR%\Sysnative\reg.exe from a Run Program action (see File System section above).

 

To access the 32-bit registry view from the 64-bit edition of Visual Build:

1.Use the Access 32-bit registry view option of the Read Registry and Write Registry actions.
2.Use registry locations that are shared by 32- and 64-bit applications.
3.Call the 32-bit %WINDIR%\SysWOW64\reg.exe from a Run Program action (see File System section above).

 

COM Object Model

 

The Visual Build object model is based on COM and is implemented as both 32-bit and 64-bit components.  To call the object model from 64-bit applications or ASP.NET on 64-bit Windows, the 64-bit edition of Visual Build must be installed or the 32-bit version of ASP.NET must be switched to.