From: Afrosheen via AccessMonster.com on
Good Afternoon. I don't know quite how to explain this but I'll try.
I have a subform where I have to enter a date. The date is validated between
a beginning and end date. If any where out side of those two dates then a
msgbox pops up. It works fine. In fact to fine.

When I try and close the main form the Subform msgbox keeps on popping up. I
don't know why this is happening. I'm not even on the subform section. I
would think that if the main form is closed then all forms would close with
it.

From the main form on the close button I have docmd.close

When the subform was in datasheet view then it worked ok. I changed it to a
continuous form so I could have more flexibility and the msgbox pops up.

I don't know what to do with it as solving this problem.
Any suggestions would be appreciated.

Thank you for reading this post.

--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/Forums.aspx/access-formscoding/201004/1

From: Stuart McCall on
> From the main form on the close button I have docmd.close

Try:

DoCmd.close acForm, "MyFormName"

where MyFormName is the name of your main form.


From: Afrosheen via AccessMonster.com on
Thanks for getting back to me Stuart.
I did try it and it seemed to work.

Thanks


Stuart McCall wrote:
>> From the main form on the close button I have docmd.close
>
>Try:
>
>DoCmd.close acForm, "MyFormName"
>
>where MyFormName is the name of your main form.

--
Message posted via http://www.accessmonster.com