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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

bold Placing a exit statement and change date on a form

Status
Not open for further replies.

bwedmund

Technical User
Oct 29, 2000
17
US
Please tell me how I can place a statement with a yes/no statement on a form so that if the person responds "yes" the form will return to a switchboard, or if they say "no", the form remains the same. I can not remember to change dates on the form. Is there a way to make to program ask you to change the date?

Thanks;

Barry
 
<b>Please tell me how I can place a statement with a yes/no statement on a form so that if the person responds &quot;yes&quot; the form will return to a switchboard, or if they say &quot;no&quot;, the form remains the same. I can not remember to change dates on the form. Is there a way to make to program ask you to change the date?

Thanks;

Barry </b>
 
private sub yesnofield after_update()
if me.yesnofield = false then
exit sub
else
msgbox&quot;change the date&quot;
me.form.switchboard.gotfocus
end if
end sub
 
Why not just set the date to NOW()? It will ALWAYS be up-todate.

MichaelRed
mred@duvallgroup.com
There is never time to do it right but there is always time to do it over
 
Please tell me how I can place a statement with a yes/no statement on a form so that when a person responds &quot;yes&quot; the form will return to a switchboard, or if they say &quot;no&quot;, the form remains the same.

I can not remember to change dates on the form. Is there a way to make to program ask you to change the date? This is done using Access 97.

The following was sent to me to use and I keep getting errors when it is in use. I also got an access 97 reference manual and I am still having problems.

I am not famalier with programming so any help would be appreciated.
private sub yesnofield after_update()
if me.yesnofield = false then
exit sub
else
msgbox&quot;change the date&quot;
me.form.switchboard.gotfocus
end if
end sub

I am not famalier with programming so any help would be appreciated.


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top