Note: I have been successful in opening a Crystal Report using this method.
Here are my requirements:
- Open a Web Intelligence Report directly from a URL while passing a parameter into the report.
- Automatically log in to Infoview (I have this solved).
I have the opendocument working just fine from one Webi report to another and passing the parameter. It just has problems as a stand-alone.
Here is the working code from the report:
="<a href=\"../../opendoc/openDocument.jsp?sDocName=City_Report&sPath=[%2E+GDOT+Reporting+Analysis+%26+Query],[Active+Reporting],[TREX]&sType=wid&sWindow=New&lsMCity="+[Govt Name]+"\">"+[Govt Name]+"</a>"
Note: the prompt is “City” and the paramater passed is Govt Name.
Now, for the URL. I copied the code from a working ASP file that successfully sends a parameter to a Crystal report, but the syntax seems to be slightly different between Crystal and Webi.
Here is the code that is giving me complilation errors.
<%@ Language=VBScript %>
<%
Dim CMS, UserID, Password, Report, Authorization, Viewer, oInfoObjects
CMS = "GDOT-GO-BUSOB3"
UserID = ""
Password = ""
Authorization = "secWinAD"
Dim SessionManager
Set SessionManager = Server.CreateObject("CrystalEnterprise.SessionMgr")
Dim Sess
Set Sess = SessionManager.Logon(UserID, Password, CMS, Authorization)
Dim LogonTokenMgr
Set LogonTokenMgr = Sess.LogonTokenMgr
logonToken = LogonTokenMgr.CreateLogonTokenEx("", 120, 100)
Dim City
City = Request.QueryString("City")
Response.Redirect
("http://gdot-go-busob4/businessobjects/enterprise115/desktoplaunch/opendoc/openDocument.jsp?&sDocName=City_Report&sType=wid&sPath=[%2E+GDOT+Reporting+Analysis+%26+Query],[Active+Reporting],[TREX]&lsMCity="&City&"&token="&logonToken)
%>
Environment: BOXI R2 SP3
If I had to guess, the problem is around the lsM area (syntax wise). But I have tried every combination that I can think of.
The URL I am creating looks like this:
http://gdot-go-busob4/businessobjects/enterprise115/CityOfficialsSelectCity.asp?Govt+Name=Adel
I need another set of eyes to look at this, so I appreciate any assistance possible.
tkdrocks (BOB member since 2003-06-10)