Note that there are some explanatory texts on larger screens.

plurals
  1. POASP.NET Cannot create ActiveX component
    primarykey
    data
    text
    <p>I have a ASP.NET application that allows users to export their staff's absences each month to Microsoft Excel. The application is currently generating the following exception</p> <p>Exception: Cannot create ActiveX component.</p> <p>with the following stack trace</p> <p>System.Exception: Cannot create ActiveX component. at Microsoft.VisualBasic.Interaction.CreateObject(String ProgId, String ServerName) at HR.ManagerSummary.ExportToExcel() in H:\Development\pagec\Visual Studio 2005\Projects\HR\ysnet2\Time\ManagerSummary.aspx.vb:line 935 at HR.ManagerSummary.btnExcel_Click(Object sender, EventArgs e) in H:\Development\pagec\Visual Studio 2005\Projects\HR\ysnet2\Time\ManagerSummary.aspx.vb:line 891 at System.Web.UI.WebControls.Button.OnClick(EventArgs e) at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) at System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)</p> <p>The code fails at the CreateObject line.</p> <pre><code> 'Create the Excel object Dim objXL As Object = CreateObject("Excel.Application") ' New Microsoft.Office.Interop.Excel.Application Dim objWB As Object = objXL.Workbooks.Add Dim objWS As Object = objWB.Worksheets(1) </code></pre> <p>I've set permission in DCOM Config for Microsoft Excel Application for the IUSR_ account but that has not resolved the issue. Any ideas would greatly be appreciated.</p> <p>Cheers</p> <p>James</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload