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

Disable the Close button

Status
Not open for further replies.

lymarist

Programmer
Feb 24, 2003
5
PR
I have an Access 2000 application and I want to hide de close button. I already try in the tools, startup. But always appear a window behind that have the principals’ commands (Minimize, Restore & Close), I want to put that options disable for the user. The main purpose is when a user enters to my application they would be obligated to fill the forms... I don't know if that is possible???????
 
Look in the properties for close button

Hope this helps
Hymn
 
Where I can find the close button properties.....Because at first I was looking for that, but I think that access does not provide that kind of functions...
 
when the form is in design view click on the properties of the form you will find the close button property in there under Min Max Buttons

Hope this helps
Hymn
 
In my opinion, hiding the "x" thingie, either for the form, and/or the Access window is a visual thing - what if the user hits CTRL+F4, CTRL+W or ALT+F4?

Here is a faq by mstrmage1768 with one way of reliably control the closing of forms and the database faq702-1870.

Roy-Vidar
 
Hi RoyVadar

Thanks for the link it works great except I've now got a problem. I originaly did something wrong and now I keep getting an error message saying "can't find the macro OK2Close = false" and I can't find where I've left the code lurking. I deleted the original mistake and have since coded it correctly. Any ideas??

Thanks
Misty69
 
If it's saying it can't find the macro OK2Close = false, my guess would be that the text "OK2Close = false" can probably be found in the event property of a control, form... somewhere. If you've followed the faq, probably the on open/on load of a form?

Roy-Vidar
 
Hi RoyVidar

Thanks but it's not in there the total error message is:
----------------------------------------------------
WLP Tidy can't find the macro 'OK2Close = false'
The macro(or it's macro group) doesn't exsist, or the macro is new but hasn't been saved.
Note that when you enter the macrogroupname.macroname syntax in an argument, you must specify the name the macro's macro group was last saved under.
-----------------------------------------------------
I've looked all over but I still can't find it. The error message only occurs when I open the database normally, if I open it in edit mode (holding down the shift key) it doesn't happen.

Any more ideas?

Thanks
Misty69
 
Hi again,

It does happen in edit mode but only when I open the form that the macro's on not on the initial opening, so It's not just lurking in the background somewhere.

Thanks

Misty69
 
Hi again again

Sorry, it was on the 'on load' on the form, for some reason I was looking on the button properties - another blond moment!

Thanks for your help

Misty69
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top