I am trying to run a crystal report based upon a lotus notes database. I have placed the CRViewer9 control in a form and have the following script. I am getting the above error: Crystal Reports ActiveX Designer: Access denied. I have given Manager rights to group I am trying to have run the report. Any suggestions would be helpful. We already have several Crystal reports running from Lotus but they access our warehouse database through an ODBC connection.
Sub Click(Source As Button)
Dim m_Viewer As Variant
Dim theReport As Variant
Dim ws As New NotesUIWorkspace
Dim Session As New NotesSession
Dim db As NotesDatabase
Dim uidoc As NotesUIDocument
Dim password As String
Dim rpath As String
Set db = session.CurrentDatabase
Set uidoc = ws.CurrentDocument
uidoc.EditMode = True
Set m_Viewer = uidoc.GetObject("Crystal Report Viewer Control 9")
Set App = CreateObject ("CrystalRuntime.Application")
Set Rep = App.OpenReport("K:\Share\Cindy\ChargeOffStmt.rpt")
Dim UserName As New NotesName(Session.UserName)
Password = ws.Prompt (PROMPT_password, "Password", "Enter your password")
Rep.Database.Tables(1).SetLogonInfo "mainoffice2/USAFCU", "chargeoff.nsf",Username.Abbreviated,Password
Set m_Viewer.ReportSource = Rep
m_Viewer.ViewReport
m_Viewer.EnableRefreshButton = 1
m_Viewer.EnableExportButton = 1
m_Viewer.EnableDrillDown = 1
Call uidoc.FieldSetText("SaveOptions", "0")
End Sub