Close Form Button

yellow

Registered User.
Local time
Today, 21:18
Joined
May 16, 2002
Messages
122
Close Form Button [Resolved...ish!]

I have disabled the close button on a form, but left the maximise and minimise buttons.

If I maximise the form the close button is enabled. Why does Access do this? Is there a way to stop this happening?

Thanking You.
 
Last edited:
When you press the max or min, you are resetting the Control.

Try Putting two buttons on your form.

In the properties for each, create an event procedure

Button1
On_Click
DoCmd.Maximise

Button2
On_Click
DoCmd.Minimise

I use key events with mine


If keycode = VbKeyF7 then DoCmdMaximise

You must set the forms keypreview to "yes" and insert the code into the KeyDown event.

This way you don't need buttons and the Control box properties Min,Max & Close can be set to "No"

Dave
 
Guess what... This is a acknowledged bug.
There are a variety of workarounds from complex (involving APIs) to simple, like setting your form BorderStyle property to none.
 
Thank you for your answers. I wanted to know if this was an acknowledged bug. I have lots of 'answers' to this but, I just want it to do what it says on the tin!

Thank you Microsoft!
 

Users who are viewing this thread

Back
Top Bottom