Avatar of BlakeMcKenna
BlakeMcKenna
Flag for United States of America

asked on 

Keep getting prompted for Parameter Entry.

I have a Crystal Report 11 with 3 SubReports in a VB.Net program. Each subreport takes the exact same parameters. The main reports' parameters match the subreports parameters in every way. Each time I try to preview the report from the app...I get the following prompt. How can I eliminate it. I have provided my VB code as well as a screenshot.

Public Function AccessGASR(ByVal strUserID As String, _
                               ByVal intGroupID As Integer, _
                               ByVal strInputType As String, _
                               ByVal strReportPath As String)
        Try
            rptErr.clsModule = "GroupActivitySummaryReportDLL"
 
            Dim crDoc As New rptGroupActivitySummary
 
            With crConnectionInfo
                .ServerName = "HERCULES"
                .DatabaseName = "Drip"
                .IntegratedSecurity = True
            End With
 
            crDoc.SetParameterValue("@userID", strUserID)
            crDoc.SetParameterValue("@groupID", intGroupID)
 
            If strInputType = "O" Then
                PrintGASR(crDoc)
            ElseIf strInputType = "B" Then
                CreatePDFReport(crDoc)
            End If
 
        Catch ex As Exception
            rptErr.clsProcedure = "AccessGASR()"
            rptErr.clsMsg = ex.Message
            rptErr.WriteToTextFile(ErrorDirectory, "DRIP-ErrorLog.txt")
        End Try
    End Function
 
    Public Sub PrintGASR(ByVal rptDoc As rptGroupActivitySummary, _
                         ByRef strUserID As String, _
                         ByRef intGroupID As Integer)
        Try
            Dim frmReport As New frmReport
 
            frmReport.WindowState = Windows.Forms.FormWindowState.Maximized
 
            frmReport.crViewer.ReportSource = rptDoc
            frmReport.crViewer.DisplayGroupTree = False
            frmReport.ShowDialog()
 
        Catch ex As Exception
            rptErr.clsProcedure = "PrintGASR()"
            rptErr.clsMsg = ex.Message
            rptErr.WriteToTextFile(ErrorDirectory, "DRIP-ErrorLog.txt")
        End Try
    End Sub

Open in new window

Screenshot.JPG
Visual Basic.NETCrystal Reports

Avatar of undefined
Last Comment
landerson999

8/22/2022 - Mon