Main Form and pop-up Form

skiphooper

Registered User.
Local time
Today, 18:37
Joined
Nov 29, 2000
Messages
76
Hi Everyone,

I have a main form which has a tab ctl on it that equates to 4 pages. During a lengthly sub procedure I call a pop-up form which gathers information on the type of text date field being read. Example: mdy, ymd, dmy, ect. plus whether it's a 4 position year, leading zeros, delimeted or not, ect, ect ,ect.

When the pop-up form loads it has with it a Error 3421 Data Type Conversion Error.

Since all my fields in my table are text, except for the one date field, the only way I can get that Error is if the code following the call to open the pop-up form is executed before the form comes up.

The code writes the date field before the field is formated to be a date.

How can I stop the code from runing once I call the procedure to open the pop-up form.

Thanks

Skip


[This message has been edited by skiphooper (edited 03-14-2002).]

[This message has been edited by skiphooper (edited 03-14-2002).]

[This message has been edited by skiphooper (edited 03-14-2002).]
 
It seems that the easiest would be to execute the rest of your code from the proper event of your pop up form (On close?)

Alex
 
Alex,

The easiest solutions always seem to be the last we think of.

Thanks

Skip
 
Hi Everyone,

Information :

I just found out if you open a pop-up form with windowmode acDialog

DoCmd.OpenForm FormName:="formname", windowmode:=acDialog

forces all vba code that follows the openform method to pause, waiting for the form to be closed or hidden.

Skip

[This message has been edited by skiphooper (edited 03-17-2002).]
 

Users who are viewing this thread

Back
Top Bottom