Hi I am having problems connecting to a SQL database using VB 6.0 and the RDC.
The code below connects me to the database CCX_GMSM using the ADO connection method when I have no database selected in the report. But when I select the same database
via the ADO connection in the report and add a field to the detail section of the report and then run the application I get the error message "Server has not yet been opened".
Can anyone tell me what Im doing wrong.
TIA Dean
Dim m_Report As New CrystalReport1
Dim cnn1 As ADODB.Connection
Dim datcmd1 As ADODB.Command
Private Sub Command1_Click()
Dim fld As FieldObject
Dim strCnn As String
Set cnn1 = New ADODB.Connection
strCnn = "Provider=MSDASQL;Persist Security info=True";Data Source=CCX_GMSM;Mode=Read"
cnn1.Open strCnn, "gmadmin", "gmadmin"