prettitoni
Programmer
I want to send fields to a crystal report at runtime, depending on the user's selection in a VB6 program. Is this possible? I'm using a dbaseIV database and ADO (DAO) in Crystal to set up the report and RDC in VB.
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Dim intMaxNumFlds As Integer
If rst.Fields.Count > 6 Then
intMaxNumFlds = 6
Else
intMaxNumFlds = rst.Fields.Count
End If
For i = 0 To intMaxNumFlds - 1
crRpt.FormulaFields.GetItemByName("col" & _
CStr(i + 1)).Text = "'" & rst.Fields(i).Name & "'"
Next i