title: Error "Retrieving the COM class factory for component with CLSID" when starting Excel
body: <p>I am running PowerShell on 64-bit machine. The line </p>
  
  <pre><code>$excel = New-Object -ComObject Excel.Application
  </code></pre>
  
  <p>gives the error </p>
  
  <pre class="lang-none prettyprint-override"><code>New-Object : Retrieving the COM class factory for component with CLSID
  {00000000-0000-0000-0000-000000000000} failed due to the following error:
  80040154 Class not registered (Exception from HRESULT: 0x80040154
  (REGDB_E_CLASSNOTREG)).
  </code></pre>
  
  <p>I researched and tried to run <code>powershell_ise.exe</code> from </p>
  
  <pre><code>C:\Windows\SysWOW64\WindowsPowerShell\v1.0
  </code></pre>
  
  <p>as explained <a href="http://www.tellingmachine.com/post/Help!-My-COM-object-fails-to-load-from-the-PowerShell-ISE-with-error-80040154.aspx" rel="nofollow">here</a>, but I still get the error.</p>