Impromptu - ASP - ActiveX Can't create object CognosImpromptu.Application
Hi !
I read a couple of articles without finding the solution ...
I'm running a report from an ASP page :
Sub Command1_Click()
Dim objImpApp
Dim objImpCat
Dim objDB
Dim Mois
Dim Annee
Dim Parameters
Mois = Month(debut)
Annee = Year(fin)
Parameters = Mois &"|"&Annee
Set objImpApp = CreateObject("CognosImpromptu.Application")
objImpApp.Visible 1
objImpApp.OpenCatalog "\\Virg\e-novacances.dev\dev\view\Impromptu\prod.cat","Auteur","", "nova","nf", 1
Set objImpCat = objImpApp.ActiveCatalog
Set objImpRep = objImpApp.OpenReport("\\Virg\e-novacances.dev\dev\view\Impromptu\absence" & ".imr",Parameters)
Set objImpCat = Nothing
Set objImpApp = Nothing
End Sub
This works fine if I visualize my asp page in Visual Interdev !
But If I use Internet Explorer, I have the error :
An activeX component can't create the object "CognosImpromptu.Application"
Before testing your control, you need to register it as design-time control. Building the control in Visual Basic doesn’t register your control automatically nor does it specify that it is a design-time control. Without proper registration, your control can be difficult to add to the Visual InterDev toolbox for testing.
Register the component "CognosImpromptu.Application" in the system registry. You can use "Regsvr32" command to register the component.
At a command prompt, type the following command:
regsvr32 "physical path of the component"
Or use MTS (in case you have a webserber IIS) to register the component.
Bookmarks