June 22, 20196 yr Newbies I am trying to use a Global field as a variable to generate a look up list, (rather than creating separate CV table occurrences). I have set up Global Table (Table A) with the necessary search field and created a Table Occurnace for the lookup field (Table B). All works fine. Problem is the delay caused by the script trigger, (I've tried all the before processing triggers) which all seem to run after I have selected the dropdown object. i.e. the list displayed doesn't update until after I've selected, or clicked away etc... It occurred me that really I'm asking the dropdown to act like a button, so I've tried to set it up as a button to run the script immediately on selection, but that then disables the dropdown function!? This must be a common problem, what am I missing? Thanks, Brad
June 22, 20196 yr Can you describe your use case using actually values? “I want the user to select from a list of active products when creating a new invoice line item,” for example. A screenshot is even better.
June 22, 20196 yr Author Newbies Images attached. The interface has: 1) Filter - top of the screen. It is a cascade filter. The script passes the parent value to FILTER VALUES table occurrence (green on the ERD) 2) Report lines - Each line of the report has a cascade lookup on the left side of the interface (Part, Section, Category, Element). The script passes the parent value to CURRENT VALUES table occurrence (Green on the ERD). When I currently select either 1 or 2, it does not update immediately i.e. the script triggers after it gets focus, so the drop list display relates to the previous values in CURRENT VALUES or FILTER VALUES as it has yet to update. Thanks
June 22, 20196 yr I’m not following. However, I’d probably just do a find using the category in the global. The find script could run onobjectsave.
June 22, 20196 yr Author Newbies I think I've just solved it. There's a fundamental problem with dropdown lists and the OnEnter script trigger. It doesn't work ahead of the list lookup. It does seem to work for a pop-up menu however... crazy... half a day wasted on that! https://www.filemakermagazine.com/videos/ultimate-value-list-control
June 22, 20196 yr Author Newbies nope... I haven't solved it. Anyone that has any idea, that'd be great
June 22, 20196 yr I'd like to help, but your terminology confuses me. You have a list of records that have a categoryId. You have a global field that has attached to it a value list of Categories (Id and Name?, showing second field only) - RIGHT? I'd do a scripted find given the Id populated in the global. What is a "cascade filter" ? What do you mean by "Global field as a variable to generate a look up list" ? What are "Report lines - Each line of the report" ? Do you mean the records? Are you new to FileMaker and so are using terminology from another platform?
June 22, 20196 yr Author Newbies Thanks for getting back to me. Insofar as I can tell, it isn't possible to use the OnObjectEnter as a trigger to update a Value Lookup that is based on a Global Field. I have instead used the OnRecordLoad trigger to run the update script ahead of selecting the dropdown. I'm not a programmer, I've waded into using Filemaker and grabbing terminology as I'm best able to understand. The db allows me to produce a Building Survey Report, which I export to Word. It pulls past records (report lines) from a Library, and conversely allows me to save Report Lines (records) to the Library for reuses. Hence, report line - is a record line in the main db. Cascaded filter, just means parent / child lookup from drop downs. The report has 3 heading levels, Parts, Sections, Categories (think legal numbering 1.1.1). Elements is a fourth level, only used in the DB to speed up finding records i.e. timber doors, metal doors... Anyway, thanks for the help.
June 22, 20196 yr 3 hours ago, Zlightbulb80 said: Cascaded filter, just means parent / child lookup from drop downs. Conditional value list. Have you considered a find? It's much simpler than complex relationships.
Create an account or sign in to comment