title: How to make COM Add-in inactive?
body: <p>I have a COM Add-in, which I want to make inactive with VBA Code (or maybe with another Excel Add-in '.xla').</p>
  <p>This is my company's internal COM Add-in.</p>
  <p>Working of this COM Add-in: While closing a workbook, a form is generated. This form asks which type of workbook (like private, confidential).</p>
  <p>This COM Add-in can be made inactive without VBA by the following method:</p>
  <ol>
  <li><p>Excel&gt;Options&gt;Add-Ins</p>
  </li>
  <li><p>Click On 'Manage - COM Addins' and 'Go'.</p>
  </li>
  <li><p>Deselect that Add-IN from Add-in manager &amp; Click 'Ok'.</p>
  </li>
  </ol>
  <p>However, after opening a new workbook the add-in starts working again.</p>
  <p>The solution to this issue is to create VBA code (/Excel Add-in) with workbook_open event to disconnect the COM add-in:</p>
  <pre><code>Application.COMAddIns(&quot;AddinName&quot;).Connect = False
  </code></pre>
  <p>But getting below error:<br />
  This add-in is installed for all users on this computer and can only be connected or disconnected by an administrator.</p>
  <p>If one can make this COM Add-in inactive manually then why is it not allowed with VBA code?</p>