A
Angel b1
Hello,
I have a Vb 6 application that prompts the user for the criteria used in a
access97 report and then prints the Access report.
I would like to see just the ONE prompt, VB OR the Access criteria prompt.
Im currently getting two prompts.
The parameter string in VB matches the one in the Access query criteria
Here is my code
result = InputBox("Enter Starting Range, MMYYYY", vbOKCancel, "Print
Invoices")
Set appAccess = New Access.Application
appAccess.OpenCurrentDatabase
"c:\vb_projects\PriorAuthInvoice\PriorAuthInvoice.MDB"
Set qrySelectCurrentInvoices =
appAccess.CurrentDb.QueryDefs("qrySelectInvoices")
qrySelectCurrentInvoices.Parameters("Enter Invoice Date:") = result
appAccess.DoCmd.OpenReport "TBLINVOICE", acViewPreview
Screen.MousePointer = vbHourglass
appAccess.DoCmd.PrintOut acPrintAll
appAccess.CloseCurrentDatabase
appAccess.Quit
Set appAccess = Nothing
Expand
I have a Vb 6 application that prompts the user for the criteria used in a
access97 report and then prints the Access report.
I would like to see just the ONE prompt, VB OR the Access criteria prompt.
Im currently getting two prompts.
The parameter string in VB matches the one in the Access query criteria
Here is my code
result = InputBox("Enter Starting Range, MMYYYY", vbOKCancel, "Print
Invoices")
Set appAccess = New Access.Application
appAccess.OpenCurrentDatabase
"c:\vb_projects\PriorAuthInvoice\PriorAuthInvoice.MDB"
Set qrySelectCurrentInvoices =
appAccess.CurrentDb.QueryDefs("qrySelectInvoices")
qrySelectCurrentInvoices.Parameters("Enter Invoice Date:") = result
appAccess.DoCmd.OpenReport "TBLINVOICE", acViewPreview
Screen.MousePointer = vbHourglass
appAccess.DoCmd.PrintOut acPrintAll
appAccess.CloseCurrentDatabase
appAccess.Quit
Set appAccess = Nothing
Expand