title: How do I run a VBScript in 32-bit mode on a 64-bit machine?
body: <p>I have a text file that ends with .vbs that I have written the following in:</p>
  
  <pre><code>Set Conn = CreateObject("ADODB.Connection")
  Conn.Provider = "Microsoft.ACE.OLEDB.12.0"
  Conn.Properties("Data Source") = "C:\dummy.accdb"
  Conn.Properties("Jet OLEDB:Database Password") = "pass"
  Conn.Open
  Conn.Close
  Set Conn = Nothing
  </code></pre>
  
  <ul>
  <li>When I execute this on a Windows 32-bit machine it runs and ends without any notion (expected). </li>
  <li>When I execute this on a Windows 64-bit machine it gets the error 
  
  <blockquote>
    <p>Provider cannot be found. It may not be properly installed.</p>
  </blockquote></li>
  </ul>
  
  <p>But it is installed. I think the root of the problem is that the provider is a 32-bit provider, as far as I know it doesn't exist as 64-bit.</p>
  
  <p>If I run the VBScript through IIS on my 64-bit machine (as a ASP file) I can select that it should run in 32-bit mode. It can then find the provider.</p>
  
  <p>How can I make it find the provider on Windows 64-bit? Can I tell CScript (which executes the .vbs text file) to run in 32-bit mode somehow?</p>