G
Guest
Could use some help on this one...
Have a fairly large, previously working Access 2K database running on XP Pro
machine. Recently made minor change to one of the forms, added two named
queries, and added three new fields to two tables. Afterward, when I run one
of the program's routines (to print a report with a bunch of imbedded
subreports), I get a "Runtime Error 6 - Overlfow" on a statement in the code
for one of the subreports. Here is the code:
Private Sub SetFormats(Optional fmtType As String)
Dim fmtMon As String
Dim fmtDate As Integer
Dim x As Long
If IsMissing(fmtType) Then fmtType = "Regular"
fmtDate = #1/1/2001# 'THIS LINE HIGHLIGHTED IN DEBUG
For x = 1 To 12
....
(Not so) Funny thing is, the recent changes are not related in any way to
the subreport whose code is being executed. The error is repeatable, and
always occurs in the same place in the code.
Tried Compact & Repair, and even creating a new database and importing all
of the objects (this sometimes works for odd Access problems) but it didn't
help. MS Knowledge Base was of no help at all (So what's new?).
Any guesses on how to fix?
Thanks,
Bruce
Have a fairly large, previously working Access 2K database running on XP Pro
machine. Recently made minor change to one of the forms, added two named
queries, and added three new fields to two tables. Afterward, when I run one
of the program's routines (to print a report with a bunch of imbedded
subreports), I get a "Runtime Error 6 - Overlfow" on a statement in the code
for one of the subreports. Here is the code:
Private Sub SetFormats(Optional fmtType As String)
Dim fmtMon As String
Dim fmtDate As Integer
Dim x As Long
If IsMissing(fmtType) Then fmtType = "Regular"
fmtDate = #1/1/2001# 'THIS LINE HIGHLIGHTED IN DEBUG
For x = 1 To 12
....
(Not so) Funny thing is, the recent changes are not related in any way to
the subreport whose code is being executed. The error is repeatable, and
always occurs in the same place in the code.
Tried Compact & Repair, and even creating a new database and importing all
of the objects (this sometimes works for odd Access problems) but it didn't
help. MS Knowledge Base was of no help at all (So what's new?).
Any guesses on how to fix?
Thanks,
Bruce