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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Help!!! - Visual Basic and Crystal RDC - Client ODBC

Status
Not open for further replies.

MattHearn

Programmer
Aug 6, 2001
1
US
Crystal Developer 8.5
Visual Basic 6.0

I am using the RDC (CRAXDRT.DLL) with VB to pull reports from a server location. I want to offload the work (and licensing)to the server location. Do I need to use ASP, or can I utilize the SetLogonInfo to access the server? (Right now I am getting "Server has not yet been opened.") What's the best way to do this. I would like to steer away from ASP. Is an ODBC connection needed for each client PC? Below is the code I have been using.

Thanks in advance for your assistance.
Matt

'General Declarations
Dim RptLocation As String
Dim RptParams As CRAXDRT.ParameterFieldDefinition
Dim CrxApp As New CRAXDRT.Application 'Application Object
Dim CrxRpt As CRAXDRT.Report 'Report Object

Private Sub Form_Load()
'Use the OpenReport method of the Application object to open the report.
RptLocation = "\\Osc5023\RptShare\RouteInventory.rpt"
Set CrxRpt = CrxApp.OpenReport(RptLocation)
CRViewer1.ReportSource = CrxRpt

'Define parameter fields
CrxRpt.ParameterFields(1).AddCurrentValue "MAH"
CrxRpt.ParameterFields(1).AddCurrentValue "DKF"

'Set the report view
With CRViewer1
.Top = 0
.Left = 0
.Width = Me.ScaleWidth
.Height = Me.ScaleHeight
.DisplayGroupTree = False
.ViewReport
End With

End Sub



 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top