Jim Stanicki
Registered User.
- Local time
- Today, 12:38
- Joined
- Aug 7, 2007
- Messages
- 36
The code below displays the form and allows me to enter the dates then gives me an runtime 2450 error on the next statement. I would appreciate someone taking a look.
Thanks
Jim
Private Sub Report_Open(Cancel As Integer)
Dim StrBegDate As String
Dim StrEndDate As String
' Put the form and get the begin and end dates
DoCmd.OpenForm "FrmStockLevelDates", acNormal, , , , acDialog
'If dates are blank load the defaults
StrEndDate = Nz(Forms("FrmStockLevelDates")!txtEndDate, "12/31/2010")
StrBegDate = Nz(Forms("FrmStockLevelDates")!txtBegDate, "01/01/2006")
'Close the form
DoCmd.Close acForm, "FrmStockLevelDates"
End Sub
Thanks
Jim
Private Sub Report_Open(Cancel As Integer)
Dim StrBegDate As String
Dim StrEndDate As String
' Put the form and get the begin and end dates
DoCmd.OpenForm "FrmStockLevelDates", acNormal, , , , acDialog
'If dates are blank load the defaults
StrEndDate = Nz(Forms("FrmStockLevelDates")!txtEndDate, "12/31/2010")
StrBegDate = Nz(Forms("FrmStockLevelDates")!txtBegDate, "01/01/2006")
'Close the form
DoCmd.Close acForm, "FrmStockLevelDates"
End Sub