4 Replies Latest reply on Dec 2, 2011 3:01 PM by techt

    I'm new to FMPA as you will soon see! Question

    gcastle

      I've worked with MS Access for years. I developed an app that did everything a truck salesman does all day long. Now I'm learning FileMaker Pro Advanced. I have my main Customer Form built. I have a field called "CID" as my unique primary key. In a another field box (on the same form) I've called "Find Customer", a pop-up field populated with all "CID" and corresponding "CompanyNames". I want to just click on my choice in the field and have the Customer record come up instantly. I've tried a few things but no luck so far. I'm probably making it too hard. I don't want to go to find mode layout and back. I could build my own "Find" LAYOUT so that I could incorporate the pop-up Find field "CID" existing Account ID's (CID)" that I want to find. But it is much faster to do it the way I did it in MS Access.

       

      In Access I just used a simple macro (the only one in my 75 mb database. Everything else is code):

       

      SearchForRecord , , First, ="[CID] = " & "'" & [Screen].[ActiveControl] & "'"

       

      I'm sure most of you reading this discussion would be able to help me.

      Thanks in advance!

      Gary Castle

       

      PS Can FileMaker Pro be set up to seamlessly down load financial information to Quicken's Quickbooks Pro?

        • 1. Re: I'm new to FMPA as you will soon see! Question
          beverly

          Gary, research script triggers. when the field is modified it can "trigger" a script to perform the find!

           

          Beverly

          • 2. Re: I'm new to FMPA as you will soon see! Question
            Mike_Mitchell

            Hello, Gary. Welcome to the FileMaker community!

             

            Yes, there is a way you can do what you're asking. FileMaker has a series of Script Triggers available (in the Microsoft world, I believe they're referred to as Event Triggers). In your case, I would implement what you want this way:

             

            1) Set up a global field with your value list attached. (You may have already done this.)

            2) Write a script that grabs the value in that field and performs a Find. Might look something like this:

             

            Set Variable [ $cid ; Find Customer ]

            Enter Find Mode

            Set Field [ CID ; $cid ]

            Set Error Capture [ On ]

            Perform Find

            Set Error Capture [ Off ]

            If [ not Get ( FoundCount ) ]

                Show Custom Dialog [ "Error" ; "No record for that ID could be found" ]

                Show All Records

            End If

             

            3) Set an OnModify trigger on that field (your global with the value list attached). Set the trigger to run the above script.

             

            Should do what you want.

             

            HTH

             

            Mike

             

            P.S. There is a plugin for QuickBooks Pro out there, yes. Not sure about how to implement; I've never used it myself. Someone else can probably chime in.

            • 3. Re: I'm new to FMPA as you will soon see! Question

              Hi Gary,

               

              We've used a different technique that preceded the arrival of script triggers and the Global Search for FMP.

               

              It comprises a Quick Search portal which we have set off to the side of our main Customer layout. Above the portal we have two fields called QS 1 and QS 2. Into these we type first few few letters of the Customer's first and last name. The Portal then displays all matching customers. A click in that portal row takes you to that Customer's record.

              Screen shot 2011-12-03 at 9.33.11 AM.png

               

              It is implemented via series of relationships to another instance of the Customers TO which we have labelled "Customers QS"

               

              Fields Last High, Last Low, First High and First Low are defined as shown here:

              Screen shot 2011-12-03 at 9.26.59 AM.png

               

              Screen shot 2011-12-03 at 9.26.35 AM.png

              and related as per the following diagram from the relationship set up dialog box:

               

              Screen shot 2011-12-03 at 9.25.29 AM.png

               

              The button on the portal row has this action:

               

              Screen shot 2011-12-03 at 9.31.53 AM.png

               

              I think you will find that this alternative to Script triggers works just as effectively.

               

              Get back to me if you need any additional help.

               

              Cheers,

               

              John

               

              John Wolff

               

              Hamilton, New Zealand

              john@gmg.net.nz

              • 4. Re: I'm new to FMPA as you will soon see! Question
                techt

                Welcome to the FileMaker community! I've used Access in the past and I've never regretted moving to FMP full time.

                 

                Lots of ways to do what you're trying to accomplish. Another method is passing a ScriptParameter based on the CID you click on, then combined with a Script Trigger, anything is really possible. It really falls to what and how you want it to work.

                 

                As for QuickBooks integration, there is a plug-in from Productive Computing that works very well. The only downside is that Intuit (the makers of QB) only has an API for the Windows version, which means that your solution will have to have at least one Windows machine with the plugin installed to function.

                 

                Good luck, and again, welcome!

                 

                TT