5 Replies Latest reply on Mar 9, 2011 9:31 AM by philmodjunk

    Need help for Global Field

    xtremu

      Title

      Need help for Global Field

      Post

      I am using Filemaker pro 11 advance New in scripting I am using my global field to find records in my database, If I enter manually any student number in my global field it works fine. Any record/s will find and enter the system time in the portal field (TimeIn and Timeout field). My problem is when I tried to add the script to clear my global field and pause and wait to enter any student number and then find the record at the same time record the system time in the portal field and it doesn’t work, my global (gStudentNumber) doesn’t work and it stock, I can’t enter any number on that field. It is possible to use this field or what is the code for this?                                                                                 I have two tables: Student and AccessLog table  Relationships Student::LogID=AccessLog::LogID                                                                                This is the script. Go to Field [Student::gStudentNumber] Pause/Resume Script [Duration (seconds): 2] Go to Layout [“AccessLog” (AccessLog)] Enter Find Mode [Pause]                                                                                   Thanks in advance for any help xtremu

        • 1. Re: Need help for Global Field
          philmodjunk

          What mode are you in when you pause the script for student input? To edit the contents of a global field, you must be in browse mode so if your script enters find mode and then pauses, this won't work.

          generally speaking, when using a global fields to capture the search criteria for this kind of script, there is no need to pause the script. Simply present the user with the layout of global fields in browse mode and include a button or script trigger to perform the script when they have finished entering criteria the in the global field or fields. The script can take it from there without any pauses.

          If you do want to pause the script (I do that when I have the search fields in a small floatint window as a way to keep the window in front), use Pause/Resume Script, not Enter Find Mode [pause].

          • 2. Re: Need help for Global Field
            xtremu
            Hi Phil, I was in Browse mode Phil while running the script, anyway I used the Pause/Resume Script [Indefinitely] and it works fine in browse mode. But if I used Pause/Resume Script [Duration (seconds): 3], Enter Find Mode [Pause] it doesn’t work,  global field in Find mode stock up, you can’t enter any number on that field. I want to clear the global field and wait any number to enter either manually or through scanner to find that record/s in the database phil. And then this  script will also record the system time in the portal (TimeIn and Timeout)  field. What is the button you are mentioning here phil? Or what is the script to resolve this kind of problem? I used already the Pause/Resume Script but still, the same problem. xtremu
            • 3. Re: Need help for Global Field
              philmodjunk

              global field in Find mode ..., you can’t enter any number on that field.

              That's precisely my point. Do not pause in find mode for the purpose of editing a global field. Do the editing of the global field in browse mode. Just use Pause Resume [indefinitely] instead of Enter Find Mode [pause]. It will look the same to the user, but they will be able to edit the global field.

              • 4. Re: Need help for Global Field
                xtremu

                Thanks a lot for the info Phil, Do you have any suggestions if their is any way to clear global field and wait any user/s to input any number on that field either manually or through scanner and find that specific record in the database ?

                Thanks for the help.

                • 5. Re: Need help for Global Field
                  philmodjunk

                  Set Field [Yourtable::globalFIeld ; "" ]
                  Pause/resume

                  Note that you can set up scanners to interact with FileMaker script triggers such as On Keystroke and OnObjectExit so that the act of scanning a barcode, or magnetic strip automatically performs the appropriate script to process the data.