The table ‘RptOpenCheck;1‘ could not be found. Error in File G:\TEMP\FO-OpenCheck {6D191F06-DECF-4A25-88FC-8553E3D435AA}.rpt: The table could not be found.
Dim crtableLogoninfos As New TableLogOnInfos
Dim crtableLogoninfo As New TableLogOnInfo
Dim crConnectionInfo As New ConnectionInfo
Dim crParameterFields As ParameterFields
Dim crParameterField As ParameterField
Dim crParameterValues As ParameterValues
Dim crParameterDefValues As ParameterValues
Dim crParameterValue As ParameterValue
Dim crParameterDiscreteValue As ParameterDiscreteValue
Dim CrTables As Tables
Dim CrTable As Table
Dim ReportName As String
Dim PrintTo As String ‘ P Printer V Window
Dim ReportPath As String
Dim UserName As String
Dim Password As String
Dim ServerName As String
Dim DatabaseName As String
Dim crReportDocument As New ReportDocument
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load, Me.Load
Dim strParam As String = Request("p")
‘获取用户请求参数
If Right(strParam, 1) = "~" Then
strParam = Mid(strParam, 1, Len(strParam) - 1)
End If
‘参数转换为数组
s = Split(strParam, "~")
‘use odbc connection database
With crConnectionInfo
.AllowCustomConnection = True
.ServerName = ”ODBCName"
‘.DatabaseName = "TempDB"
.UserID = "sa"
.Password = "Microwin"
End With
crParameterDefValues = Nothing
crParameterDefValues = New ParameterValues
crParameterDefValues = crParameterField.DefaultValues
crParameterDiscreteValue = Nothing
crParameterDiscreteValue = New ParameterDiscreteValue
If i > (j - 2) Then
Select Case crParameterField.ParameterValueKind
Case ParameterValueKind.BooleanParameter
crParameterDiscreteValue.Value = False
Case ParameterValueKind.CurrencyParameter
crParameterDiscreteValue.Value = Nothing
Case ParameterValueKind.DateParameter
crParameterDiscreteValue.Value = System.DateTime.Now
Case ParameterValueKind.DateTimeParameter
crParameterDiscreteValue.Value = System.DateTime.Now
Case ParameterValueKind.NumberParameter
crParameterDiscreteValue.Value = Nothing
Case ParameterValueKind.StringParameter
crParameterDiscreteValue.Value = " "
Case ParameterValueKind.TimeParameter
crParameterDiscreteValue.Value = System.DateTime.Now
End Select