close button

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

Guest

Is there a way of writing into my code to enable or disable the forms close
button. I know you can go into the form's properties and do this, but I want
the close button not to be functional when the form is populated (thus giving
them my exit button), but functional when the recordset is zero and gives me
nothing on the form....Thanks for the help
 
Michael

Wouldn't that mean that users would have to learn TWO different ways of
closing a form? Wouldn't it make it slightly easier if the way they closed
the form was ALWAYS the same?

Regards

Jeff Boyce
Microsoft Office/Access MVP
 
Probably, but everyone that is going to be using this program would know how
to use the close button, so having them use a close button wouldn't be a
problem. I just wanted to regulate how they close the forms usually by
eliminating the close button and giving them an exit access button. By doing
this though, I run into the problem of having no access buttons on a form
when the query returns nothing.
 
Great thought! It worked. I used a nonvisible button and on form load, if the
recordset is zero (meaning the query displays nothing), turn it to visible.
So, there is a button for them to exit the screen if the query returns
nothing and a button if it does return something (the normal button). Thanks
for the help Adam!
 
Back
Top