Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

XI R1 viewrpt.aspx method still same/similar in 3.1?

Status
Not open for further replies.

pgmr777

Programmer
Aug 16, 2006
111
US
We are running XI R1 and calling reports url method using a custom app like this:

****************app code***********************
Dim svr As String = System.Environment.MachineName
'Dim qs As String = "&" & Context.Request.QueryString.ToString
Dim arpt() As String = Split(rptval, "|") 'Context.Request("rpt")
Dim rpt As String = arpt(0).ToString
Dim xrep As String = arpt(1).ToString
Dim uid As String = arpt(2).ToString
If rpt = "" Or rpt = "undefined" Or xrep = "" Or xrep = "undefined" Or uid = "" Or uid = "undefined" Then
Return "notfound.htm?params=0"
Exit Function
End If
'Dim cmd = Context.Request("cmd")
Dim cesm = CreateObject("CrystalEnterprise11.SessionMgr.1")
Dim ces = cesm.Logon("administrator", "nimda0", svr, "secEnterprise")
Dim ceis = ces.Service("", "InfoStore")
Dim cetokmgr = ces.LogonTokenMgr
Dim cetok = cetokmgr.CreateLogonTokenEx("", 2, 100)
Dim sSQL As String = "Select SI_ID From CI_INFOOBJECTS Where SI_PROGID = 'CrystalEnterprise.Report' AND SI_INSTANCE = 0 AND SI_NAME = '" & rpt & "'"
Dim rID As Integer
Dim ceio = ceis.Query(sSQL)
Dim init As String = ""
If ceio.count > 0 Then
rID = ceio.item(1).ID
Else
Return "notfound.htm?norpt=1"
Exit Function
End If
'If cmd = "" Then init = "&init=java_plugin:connect"
init = "&promptex-Xrep=" & xrep & "&promptex-UID=" & uid & "&cmd=export&export_fmt=u2fpdf%3a0"
Return "/crystalreportviewers11/viewrpt.aspx?id=" & rID & "&apstoken=" & cetok & init
cetok = Nothing
cetokmgr = Nothing
ceis = Nothing
ces = Nothing
cesm = Nothing
****************end app code***********************

My question is, if we upgrade to 3.1 will this still work other than changing the object names and paths, etc?

Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top