Jump to content

can one remove the close window box?


This topic is 6409 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Hi Digitaljunkie

Using the custom menus in FileMaker 8 Advanced is what it sounds like you need, you can assign a script to the close file menu option which incorporates the [X]Close Window Box.

In this script you can ask if the user is sure they want to close the file, quit or cancel the request. From there response you can close the file, quit the application or end the script which will not close the file.

A script I often use is something like this:

Show Custom Dialog [ Title: "Message"; Message: "Do you want to close or quit this file?"; Buttons: “Cancel”, “Close”, “Quit” ]

If [ Get ( LastMessageChoice ) = 3 // Quit ]

     Exit Application

Else If [ Get ( LastMessageChoice ) = 2 // Close ]

     Close Window [ Current Window ]

End If

 

 

You can access the Custom Menus via: Tools – Custom Menus – Define Custom Menus

You can also set up different responses for different areas of the system by assigning separate menu sets to certain layouts.

I hope this helps.

Orlando

Link to comment
Share on other sites

Also if you want the option of disabling the 'X' for the entire application for the Windows side, you can take a look at this plugin. It is decently affordable. http://www.medeyedbs.com/WindowUtility.htm

Link to comment
Share on other sites

Do you see the message?

The only thing I can think it might be is the order of the buttons.

the order you need is:

Default Button = "Cancel"

Button 2 = "Close"

Button 3 = "Quit"

And you also need to make sure the custom menus you setup is the one being used at the time you hit the close button.

Orlando

Link to comment
Share on other sites

ok maybe Im being dumb...

Hi Digitaljunkie

Using the custom menus in FileMaker 8 Advanced is what it sounds like you need, you can assign a script to the close file menu option which incorporates the [X]Close Window Box.

I thought this was the File Options>Run Script When Closing File.

But obviously its not.

Where is the above mentioned close file option.?

Edited by Guest
Link to comment
Share on other sites

digitaljunkie,

Straggler is talking about creating a custom menu. Except a few functions such as Exit application etc, you can reassign most menu items with your own scripts. So he is telling you to create a custom menu and override the Close menu with your own script. When you go to close the window with the 'X' it will look to run the 'Close' function but since you replaced it with your own script it will run that rather than just closing.

Link to comment
Share on other sites

Dont worrie its an easy mistake to make

You need FileMaker Pro Advanced and go to

Tools > Custom Menus > Define Custom Menus

I would check out the FileMaker Help and get some background on Custom Menus before implementing them. But to just make this small change here is a brief run through.

Create your script called 'CLOSE'

Open the custom menu dialogue, Tools > Custom Menus > Define Custom Menus.

First you want to change the default menu for the file, this is at the bottom of the dialogue, change this to 'Custom Menu Set 1' this menu set is a copy of the default FileMaker set so there will be no difference in functionality.

Now we need to edit the close option:

The main window in the dialogue is a list of all menu items, double click on "File Copy" and the Edit Custom Menu Dialogue should pop up.

This will show you the sub menu items for File.

Select 'Close'

And to the right, under Menu Item Properties check the box marked 'Action' select 'Script' from the drop down and then click 'Specify'

Select the CLOSE script and job done.

I hope this is detailed enough, and makes sense.

Orlando

Link to comment
Share on other sites

You can assign the custom menu Straggler outlined to a particular layout (look in the Layout Setup dialog), and/or to a particular privilege set (Accounts & Privileges), or script it (Install Menu Set, in the Miscellaneous section).

Link to comment
Share on other sites

This topic is 6409 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.