Jump to content

Pop-up Menu Choice to trigger script

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

Recommended Posts

Hi I want to have a user's selection of student grades from a pop-up menu automatically select a script that performs a find.

The students are grade 4,5 or 6. (on the value list: SELECTGRADE)

and I want to draw only the appropriate grade from the school records based on what grade the user selects.

Rather than have a "GO" button scripted to begin the find script, is there a way that as soon as the menu choice is made that the script begins based on the value chosen?

Also, should I have a find script for each grade level... not sure how to set this up.

Thanks in advance,


Link to comment
Share on other sites

Filemaker can't run scripts when the input of a field changes or on an exit of a field. You need a plugin for that to work! Try the Do-Script plugin (www.fmplugins.com). Put the plugin in your filemaker extensions folder (apple) and make a calcfield named TriggerScript in the database where you select your selectgrade valuelist. In the calculation place the following data:

field & External ("dscr-doScript", "script")

Where field is your field with the selectgrade valuelist and script is the script you want it to run on a change of selection in the field.

This should work fine...good luck


Link to comment
Share on other sites

for what you want to do with the popup menu, SCRIPTit works better than doScript. i am using both plugins right now in an invocing/project management system i am developing for a client. and i am using SCRIPTit for a system navigation popup. they click on the popup, choose what module they want in the solution, and it runs that script. best part about SCRIPTit is it is XML based, all you do is change a XML file to change the contents of the popup menu. check it out:


if you use doScript, you will have to have one single controlling script with a lot of if/then statements in it, pointing to many subscripts. i first setup my navigation popup this way with doScript (after getting tired of the "GO" button myself) and it is a lot more work to do this in doScript than with SCRIPTit.

here is how i have SCRIPTit setup:

you need a result field, "SCRIPTit Result" in your db

you need a script with a Set Field:

Set Field ["z g SCRIPTit Result" , "

External("Scrp-DefineXMLFile", Preferences::pr g Path to XML)


External("Scrp-DefineXML", "<menu name='Nav' defaultdb='" & Status(CurrentFileName) & "'>

<insertmenu name='Main_Menu' /></menu>")


External("Scrp-ShowMenu", "name=Nav, x=543, y=42")"

attatch the script to an image or even a field on your layout. i have a preferences file, so i am pulling the XML path from it. now for the xml file:


<menu name="Main_Menu">

<menuitem name="Main Menu" script="[EXT] Open Main" />

<menuitem name="-" />

<menuitem name="Clients" script="[EXT] Open Clients" />

<menuitem name="Client Contacts" script="[EXT] Open Contacts" />

<menuitem name="Vendors" script="[EXT] Open Vendors" />

<menuitem name="Vendor Contacts" script="[EXT] Open Vendor Contacts" />

<menuitem name="Employees" script="[EXT] Open Employees" />

<menuitem name="Past Employees" script="[EXT] Open Past Employees" />

<menuitem name="Invoices" script="[EXT] Open Invoicing" />

<menuitem name="Reports" script="[EXT] Open Reports"/>

<menuitem name="Archive" script="[EXT] Open Archive " />

<menuitem name="-" modifierkeys="ctrl+shift" />

<menuitem name="Preferences" modifierkeys="ctrl+shift" script="[EXT] Open Preferences" />

<menuitem name="-" modifierkeys="ctrl+shift" />

<menuitem name="Unigraphics Help" script="[EXT] Open Help" />



the X and Y cords. in the script are were you want them to show up on your layout.

here are a screen shot. also SCRIPTit is cross platform.


Link to comment
Share on other sites

This topic is 7815 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.