title: OLE Error in SQL
body: <p>I have Windows Server 2003 Standard x64 Edition SP2 with </p>
  
  <p>Microsoft SQL Server 2005 - 9.00.4035.00 (X64)   Enterprise Edition (64-bit) on Windows NT 5.2 (Build 3790: Service Pack 2) </p>
  
  <p>I downloaded CAPICOM Platform SDK Redistributable: <a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=860EE43A-A843-462F-ABB5-FF88EA5896F6&amp;displaylang=en" rel="nofollow noreferrer">http://www.microsoft.com/downloads/details.aspx?FamilyId=860EE43A-A843-462F-ABB5-FF88EA5896F6&amp;displaylang=en</a></p>
  
  <p>and installed it from 
  c:\Windows\syswow64 with c:\Windows\syswow64\regsvr32.exe capicom.dll and it got registered succesfully.</p>
  
  <p>When I tried to run </p>
  
  <pre><code>DECLARE @S varchar(255) 
  DECLARE @D varchar(255)
  DECLARE @O int
  
  EXEC @C = sp_OACreate 'CAPICOM.EncryptedData', @O OUT
  IF @C &lt;&gt; 0
  BEGIN
    EXEC sp_oageterrorinfo @O, @S out, @D out 
    SELECT err=CONVERT(VARBINARY(4),@C), source=@S, description=@D
    RETURN
  END
  </code></pre>
  
  <p>and I got error message.</p>
  
  <pre><code>0x80040154  ODSOLE Extended Procedure    Class not registered
  </code></pre>
  
  <p>What should I do? How should I check if CAPICOM.DLL is correctly registered?</p>