Newbies zepnut Posted October 5, 2006 Newbies Posted October 5, 2006 My users want to sort a portal by any column. Easy I thought..... Make the title into a button and use it to set the value of a global field (in the same table as the portal) and set the portal to be sorted by that field. The field gets set by the button script but the portal doesn't change. I then added a refresh window step and it still doesn't work. I also flushed the cached data - still no good. Anyone know why that doesn't work? Most irritating!
Genx Posted October 5, 2006 Posted October 5, 2006 ... a global is a global, it's value is the same for every single record, if you're sorting by the global, and you've set the value to for example: "Phone" filemaker sorts the records, but every single record (seeing as you are using a global field) has the value "Phone", so the current sort order doesn't change. What you can do however, is have a look in the sample files section, i'm pretty sure someone posted a nice way of putting portals on tabs to make it look like you're column sorting.
brian rich Posted October 5, 2006 Posted October 5, 2006 Try adding a commit records (skip validation, no dialog) after you have set the global. FMP8.5 seems to do very little with relationships unless you force an update. Brian Rich ruralnet|uk
Søren Dyhr Posted October 5, 2006 Posted October 5, 2006 I kind of dissagree every time someone mentions anything global'ish, sorting portals is a relational and a layout matter not something to do with bloating a table with fields and something to script: http://www.filemakerpros.com/LessSort.zip --sd
Newbies zepnut Posted October 12, 2006 Author Newbies Posted October 12, 2006 Thank you all for your help. Søren you are a clever dude. I really like that. No Scripts! Genius Everyone should have a copy of the LessSort zip. It shows a different way of thinking. All solved!
chrisk1 Posted November 7, 2006 Posted November 7, 2006 I don't understand how creating a global field to sort the portal by, then writing a two step script to assign a value to the global, is considered bloating. Including assigning field names as button parameters to sort your portal by, this takes no more than 5-10 minutes. I just finished creating all the necessary tabs for headers in my portal (six times 2 for asc and dec), then copied and placed all the portals for the tabs, had to set the sort for all 12 portals, refomatted the tab titles to align properly (not even wanting to think how this will eventually display in XP), then had to monkey with making sure my arrow graphics were aligned correctly over the right tabs while retaining consistency from column to column. This took nearly an hour, but it does work. I only have about 25 more portals I need to do this to. I just don't understand why there isn't a way to script switching from ascend to descend per column. This makes about as much sense as FileMaker not natively scrolling a portal horizontally.
Recommended Posts
This topic is 6591 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 accountSign in
Already have an account? Sign in here.
Sign In Now