Jump to content
Sign in to follow this  
Wickerman

Scripting Find For Artists *or* Artworks

Recommended Posts

I'm revisiting a Filemaker Go solution I put together a few years ago where I implemented a clumsy workaround for a problem I couldn't figure out.  I have a database that stores ARTIST records and child ARTWORKS records, and I have a layout with a bunch of searchable fields drawn from both tables so that the user can search for, say, American (Artist field) & Watercolor (Artwork field) 

I'd like the user to be able to specify whether the Find will display a list of ARTISTS (American watercolorists) *or* ARTWORKS (Watercolors by Americans).

Currently, I have two buttons on the layout, so when the user enters his search terms, he taps the appropriate button and a script takes him to a layout with the appropriate context and results (I put a Script Parameter on the Find Artists button).  This works okay, but it is really inelegant and non-intuitive, because in Find mode the Keyboard is on display for entering the search terms, including a big blue irrisistable "GO" button that invites the user to execute the search -- which is of course not going to do what I want it to do.

Is there a way for me to use a Script Trigger that would intercept the Find action and perform my branching script instead of delivering the native Find based open the current context?  I haven't been able to figure it out -- perhaps an OnModeExit? I've gotten kind of confused about what happens to the search result and when a script might intervene.

An alternative is I suppose I could just give the user a choice of two layouts to go to depending on whether he wants to search for Artworks or Artists -- adding a step to the search process.

Suggestions?

 

Share this post


Link to post
Share on other sites

Can you add a radio button as part of the search that does this specification? Then you can branch based on its value...

Share this post


Link to post
Share on other sites

Webko -- thanks for the suggestion. THat seems likethe kind of thing I want to do - - but I'm hazy on the mechanics.  How do I trigger he script to run?  The user fills in the search field, including a radio button, then taps "Go" and filmmaker runs the Find on the current context .  . .  . I assume I'd attach a script to a Script trigger on the layout so that after the Find executes, this additional thing happens.  But I'm unclear on what trigger to use (Record load?  Mode exit?  Mode Enter?). . . or whether I'm not even thinking the right approach her?  I may be missing something obvious!

Share this post


Link to post
Share on other sites

Add the script to the button object - no need for a trigger

I would make the radio button a global text field - Artists_Works_g perhaps

Then the script called when pressing the button uses an if based on the value of the field to perform to go to the correct layout and perform the correct search

Share this post


Link to post
Share on other sites

Ack -- I'm either not getting my situation across or just missing the obvious -- the "Button" is on the slide-up keyboard on the iPad -- is it possible to attach a script to a button that is not on the FIlemaker layout, but on the built-in iPad keyboard that appears when you type in any app?  As far as I'm aware the 'Go' button just executes the search?  Here's a picture of the screen -- you can see the buttons I set up and how they are 'upstaged' by the ipad-native 'Go!' button.  

ipad.jpg

Edited by Wickerman

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Similar Content

    • By owangolama
      Hello. Working on my first FMGo solution. I've locked the zoom and turned off the menus so that things aren't crazy bouncing around all the time.
      I have a large detailed graphic in the middle of the layout. I would like the user to be able to zoom and slide that graphic to see more detail and or simply move around the visible portion. Can I use gestures to do this? (Pinch, expand, and finger slide, or whatever that's called.) If so, how would I go about figuring this out (I couldn't find an example anywhere).
      Thanks in advance for any help!
    • By Greg Hains
      Good morning.
      I am getting a status message appear at the bottom of my iPad (that black pop up bar) with my Go solution:  "Old location received. New location requested".
      It's not a problem, doesn't seem to take long to go away, but I've never seen it before - and can't find any reference to it through Google searches.
      My Internet connection from the iPad is fast - it happens both on 4G and through a wireless connection. I can find no consistency as to the cause.

      My solution is using CURL functions, so wasn't sure if it was related to that at all - e.g. a message from the host.

      Can anybody shed some light on this please?
      Greg

       
    • By Greg Hains
      Good morning.
      Does anybody know how to launch IOS apps from Go please? I am looking to open the calculator.
      Greg 
    • By zonetuke
      My primary Filemaker 16 database connects to 4 other tables located in their respective Filemaker databases. I wish to prevent these connections from occurring when using the primary Filemaker database in Filemaker Go in iOS but allow the connections when using on a computer desktop, both Mac and Win. The reason I wish to disable these connections in iOS is that I always see prompts to locate the databases and it wastes my time to locate each one and connect it. Any way to accomplish this?
    • By Paul Hunt
      I run a small, one-person business and would like to find a hosting solution for a few small, low-use databases. Mostly I just enter some customer charges and lookup passwords, at most three times a day. The cheapest I have found is $29/month and that is more than it is worth to me. Is there any solution out there for around $10/month?
       
      Thanks,
      Paul
×
×
  • Create New...

Important Information

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