Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Date Picker error message

Status
Not open for further replies.

JBG

Programmer
Joined
Oct 22, 2001
Messages
99
Location
US
I have an Access 97 database with a tab control form (4 pages). Each page has numerous ActiveX date/time picker calendar controls.

When the program terminates at run time with this click event:

Code:
Private Sub cmdQuit_Click()
    DoCmd.Quit acQuitSaveAll
End Sub


or when I close the form in design view, I get 1-5 errors messages that all state:

"An error occurred in a call to the Windows date and time picker control."

There is no error number, no other words, nothing. Just the generic message.

Strangely enough, when the program is running and I close it by executing the above click_event, I usually get just 1 or 2 of the "An error occurred..." error messages, but when I am designing, and then close the form, I get the full onslaught (up to 5 or so).

Throughout the tab pages, I set the value of all of the date/time pickers with the following generic code:

Code:
Me.DateTimeControl.SetFocus
Me.DateTimeControl.Value = Nz(Me.FieldValue, "")

I have tried to trap for whatever error this message is
associated with. When I trap in the unload event's error handler, I get err.number 0 and no message, then with the 'Resume next' (still in the err handler of the unload event), I get err.number 20 and err.description that says there is no error description (neat). Then I get the "An error occurred..." error message several more times, and the deactivate and close events never fire.

Any help would be most appreciated as this error appears to be untrappable and the db is going into production.

Sorry for the long post - I'm desperate.

email to: Jeff.B.Goodman@wellsfargo.com

Thanks,
JBG

 
I don't know if this will solve your problem - But I had problems with the Date and Time picker at one time - and don't ask me why I did this, but I installed VB6, and ever since then, I have had no problems. The only downside is that where ever I have the application program, I also need to install VB6 - but hey! the thing works.

I know this is probably useless - but it might work.

Martin.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top