Can you point to a particular Starter Solution for example, so we may assist you further?
Also including screen shots (or print to pdf) of your script(s) so we may compare to the original will be beneficial.
Thank you for your quick response!!!
Sure, I'm using FM15 Pro and working from the Invoice starter solution.
It's within the 'Products' table that I am trying to modify the sort selection pop up menu.
I have created a field "category" which is a radio button set to categorise items to "active" and "inactive". My aim is to sort through all records via this field so that I can display all items currently marked as "active (in stock)".
I've attached a screen shots of the trigger for the field 'sort selection', the sort selection calculation and the sort list key calculation. I hope that this helps and we can solve this! Thank you!!
If you merely are trying to FIND by 'active' (and then sort), you can enter find mode, click the "active" and perform find (or script this process). Because it is a selection list, you must "trigger" the change to perform a script. Study the example Invoice again for what script gets called. You want to change it find, not sort.
1. click once on the field in layout mode and then select "Set Script Triggers" from the "Format" menu
2. click the "Select" button (to choose the script)
3. that should be selected in the list, so while highlighted click the "gear" icon at the bottom to Edit the script
( I see by your Screen shots, that you have done this! )
4. The script should be:
Enter Find mode ( NO pause! )
Set Field ( <<your field in the table that shows "active/inactive">> ; Products::Sort Selection )
Scroll Window (Home)
I may not have the correct fields. But you should see this FINDING by selection.
I see now that at this point the sort selection field is functioning more as a find then a sort for my database, however it would be good to include other key fields in the pop up menu (i.e. such as title, artist). If I did this, I presume the sort selection field would function more as a sort than a find.
I would just like an easier way to bring up relevant information through a pop up menu rather than going through the sort records button in the toolbar.
I really like this component in the Invoice started solution and would love to replicate it but with my own custom values.
Is this possible through a sort selection script?
Yes! study the Invoice Sort script and notice that is uses "if/else" branches to perform actions based on the selection.
If you want to FIND that way, make your list in such a way as to Find how you want:
Then "branch" based on the selection. However, you are getting into finding variable information. Surely you will not list every artist! But the branch can be something as simple as:
Enter Find Mode
Go to field ( artist )
That allows entry into the field "artist" for searching by what the user types. When they are done, the "Enter/Return" restarts the script and actually performs the find.
You may wish to study the Find script steps as well as the other help topics on Searching.
The starter solutions are criminally lacking in documentation to tell (especially newbie developers) how they work.
Here's a teaching file showing many different value selection techniques--each with detailed documentation on how they were set up and how they work:
Ok great, I'll take your advice and look into the Find scripts.
Just to clarify could I then trigger this Find script to the sort selection field if it is set to pop-up menu or would it be best to change it to an edit box? Or perhaps it does not matter...sorry I'm very new to this!
Thanks for your help with this Beverly. Much appreciated
Agreed...as a newcomer to filemaker I would not have gotten anywhere without this forum. I have found it extremely difficult to find further documentation in regards to creating and modifying features of FM.
Thanks for the link, excellent!
I have found it extremely difficult to find further documentation in regards to creating and modifying features of FM.
Don't know why it would be so hard. There's lots and lots of documentation, just not in the starter solutions.
Then look at what's offered on Lynda.com, Youtube and there's a number of Blogs on FileMaker design that can be web searched.
Difficult to select and incorporate different features of all the starter solutions into one custom built solution!