Hi!
I would like to know if anyone knows how to dinamically change the DSN of my reports, I have my reports running on the RAS, I send them the username, password and the report parameters and they work fine, but they use the DSN saved on the report... I want my user to be able to change the DSN from the application, does anyone knows the rigth objects to do that? does anyone has an example of it?
Here is my code:
<%
dim Path
dim iLen
Path = Request.ServerVariables("PATH_TRANSLATED"
While (Right(Path, 1) <> "\" And Len(Path) <> 0)
iLen = Len(Path) - 1
Path = Left(Path, iLen)
Wend
Dim ReportDoc, objFactory, rptAppSession
'Use the ObjectFactory object to abstract the version number
'to one location
Set objFactory = CreateObject("CrystalReports.ObjectFactory.2"
Set Session("objFactory"
Set rptAppSession = objFactory.CreateObject("CrystalReports.ReportAppSession"
' The name of the ReportAppServer is specified in clientSDKOptions.xml
rptAppSession.Initialize
Set Session("rptAppSession"
'Create a new ReportClientDocument object for this reportAppSession
Set Session("oClientDoc"
'Open the report
Session("oClientDoc"
Session("userName"
Session("password"
Session("oClientDoc"
after this there are only parameters managment but that was my connection settings