Cancel Button

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a button on my form that when you press the button it asks you to
enter the date. If you press the cancel button it shuts the form down and
takes you to the database window. Is there a way that if the cancel button
is pushed that the form will remain up? Can someone please help?
 
WMorsberger said:
I have a button on my form that when you press the button it asks you
to enter the date. If you press the cancel button it shuts the form
down and takes you to the database window. Is there a way that if
the cancel button is pushed that the form will remain up? Can
someone please help?

Eliminate the button's code?

Seriously, I assume you mean that "under certain conditions" you want the
Cancel button to behave differently than it normally does. What are those
conditions and what do you want it to do differently?
 
Currently the button that I have is associated with a query. When the button
is pushed it asks you to enter a date. If someone pushes that button, then
decides that they pushed the wrong thing, when they press the cancel button
to get rid of the message the whole form shuts down and they are taken to the
database base menu. I want the user to have the option to press cancel but I
want the form to stay up.
 
WMorsberger said:
Currently the button that I have is associated with a query. When
the button is pushed it asks you to enter a date. If someone pushes
that button, then decides that they pushed the wrong thing, when they
press the cancel button to get rid of the message the whole form
shuts down and they are taken to the database base menu. I want the
user to have the option to press cancel but I want the form to stay
up.

Is this a code generated InputBox or a parameter prompt from the query?
 
WMorsberger said:
It is a parameter prompt from the query

Post your code then. There is no reason why pressing cancel should cause
that unless your code is handling the query incorrectly or the query is
corrupted.

If you run the query from the db window and press cancel on the parameter
prompt what happens?
 
I didn't write code for the button - The form is based on a query, so there
is a macro on the button that tells the button to open the new form and the
close the form that it is currently on - when you press the button you are
prompted for the date and if you cancel out of it then the other form has
already closed - I guess now after writing this I can just change the macro
to leave that form up
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top