Jump to content
Sign in to follow this  
Sanjai

Dynamic sort and renaming menus

Recommended Posts

Hi,

I want to give my users a functionality where they can select a value from a pop up list so that everytime whenever user does any search or show all records function, my script would sort the records in the found set based on the value selected in the pop up list. These values are nothing but the field names. This is just an effort to keep something dynamic.

I tried creating a global text field and a value list with some field names. But then I found that Filemaker Pro does not allow sorting on global fields. Is there any way I can do this?

Secondly, I have seen in some of the proprietory Filemaker files that the menu named "Scriptmaker" is renamed with the organization name eg: "EZXSLT". How do we do this?

Waiting for your quick feedback,

--Sanjay

Share this post


Link to post
Share on other sites

Hi,

Take a look at the Sample section, as I posted a file called DynamicSort a while back.

If it doesn't suit your needs, may be you could try to add an occurrence of your Table, renamed say "SortingTable" and use a Cartesian Join, using an unstored calculated field as the sort key (using GetField( ) here)

I can't test it, but a script GoToRelatedRecords should do the trick, may be involving a Refresh Window step.

You may also need to display and set the global from "Sorting Table" rather than the current Table gField.

HTH

Share this post


Link to post
Share on other sites

Hi,

Thanks for your help. I'm sorry to ask but could you please let me know where can I look for the sample section?

Thanks,

--Sanjay

Share this post


Link to post
Share on other sites

Hmmm...

http://www.fmforums.com/threads/postlist.php?Cat=0&Board=files

You need to log-in which is probably why you didn't see this section.

http://www.fmforums.com/threads/showflat.php?Cat=0&Board=files&Number=126771

is the EasySort demo link.

Share this post


Link to post
Share on other sites

Hi,

Thanks for your reply. I checked it and understood the script which you wrote. I would like to implement this but I have a question here for maintanence. As compared to only three values in your value list(name, any number and any date) I want to give my users a value list which would be filled with more than half of the field names from the existing database. It is ok if I don't concentrate on graphics here but I am looking for a functionality where in future if someone adds a field and wants to give users a flexibility to sort on the newly created field, manually adding that field in the value list should automatically take care of everything.

I apologize if your logic already provides such flexibility but if yes then could you please let me know how we can implement it.

Thanks for taking out your time. Waiting for a reply.

--Sanjay

Share this post


Link to post
Share on other sites

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
Sign in to follow this  

×

Important Information

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