3 Replies Latest reply on Jul 5, 2010 4:27 PM by philmodjunk

    Filtering and Video



      Filtering and Video


      Hi I am creating a horse racing database, and have 2 questions: 1. I need to be able to filter races by the season. The racing season starts 1st of august and ends 31st july following year. Please could someone tell me if its possible, and how to have a drop down menu with the each seaon in it eg 2003/2004, and when a partcular seaon is selected it filters the races only for that season ? 2. Is it possible to have 2 differnt buttons to 2 different videos off 1 record? Any help is appreciated. Thanks

        • 1. Re: Filtering and Video

          I need to be able to filter races by the season.

          I suggest you add a new table where one record represents one season. At the very least, you'll need two date fields to record the beginning and end of that season. If you have a Races table with a date field to record the date of the race, you can set up a relationship such as:

          Seasons::DateStart < Races::RaceDate AND
          Seasons::DateEnd > Races::RaceDate

          Now you can place a portal to Races on your Seasons layout to list all races that took place in that season. You can place a button that uses either Go To Related Records or a scripted find to switch the user to a Race layout displaying that race when you click the button next to that race name in this portal.

          Is it possible to have 2 different buttons to 2 different videos off 1 record?

          I suggest a third table, Videos linked to your races table like this:

          Races::RaceID = Videos::RaceID

          Then a portal to Videos on a Races layout can display as many videos for a given race as you need as each vidoe can be stored in a different related record in Videos and be linked to the correct Races record by RaceID.

          This is just a broad outline. I suggest looking portals and container fields in the filemaker help system to learn more. See how much you can get working and feel free to post back here when you get stuck.

          • 2. Re: Filtering and Video

            Thank you for your quick response...I will play around and see what i can accomplish :)

            Sorry, one other question, is it possible when scrolling down my records in "list view" to highlight the row that i am currently on, instead of just a small arrow next to it ? I have tried to find an answer for this in the forums, but see that its been a problem in the past versions, has it been fixed now?

            Thanks again for your help.

            • 3. Re: Filtering and Video

              I wouldn't say it was ever "broken". Having the current record highlighted in that fashion isn't always desirable.

              You can combine script triggers, a global field and conditional formatting to get this effect if you want to.

              1. Define a global number field: gCurrentRecord
              2. Write a one line script: Set Field [Yourtable::gCurrentRecord ; Get ( RecordID ) ]
              3. Use Layout Setup to select this script for the OnRecordLoad trigger
              4. Use this expression: Get ( RecordID ) = Yourtable::gCurrentRecord to set a fill color for each field in your list body.

              Now, selecting a record in the list will cause the conditionally formatted fields to "highlight" with the color you selected.