3 Replies Latest reply on Oct 13, 2010 2:30 AM by sunmoonstar.13

    listing all values

    DickSchaffa

      Title

      listing all values

      Post

      Hi,

      In my FMP dartabase I am using a indexed textfield where users can type 'tags' for that record. On de 'Formview' this textfield is 5 lines in height, so users can add up to 5 'tags'. The index makes that if a users types a letter they see they already used 'tags' starting with that letter, which works fine

      Nect to that I want users to be able to see a complete list of used 'tags', where every used tag value is only shown once. I've tried to do this with a table view, but values are show multiple times and I can only see the first 'tag' of te indexed text field.

      Is there a wat to do this?

        • 1. Re: listing all values
          sunmoonstar.13

          One solution would be to create a Value List using the values of your text field, then create an unstored Calculation field using the calculation:

           

          ValueListItems ( Get ( FileName ) ; "your_value_list" )

           

          Nick

           

           

           

          • 2. Re: listing all values
            DickSchaffa

            Could you tell me howto? I'm trying to figure out how to do this all, but get stuck after te first step

            • 3. Re: listing all values
              sunmoonstar.13

              To create the Value List:

              Go to File menu > Manage > Value Lists, then click the "New" button. Type Tag_values in the Value List Name field, then select "Use values from field". A dialog window will open.  Select your table from the dropdown menu, then select the text field that contains your tags. Then click OK and exit all the dialogs.

               

              To create the Calculation field:

              Go to File menu > Manage > Database. Click the Field tab, type Tag_calc in the Field Name field, select "Calculation" in the "Type" dropdown menu, then click the "Create" button. A dialog window will open. Enter the following calculation:

               

              ValueListItems ( Get ( FileName ) ; "Tag_values" )

               

              Select "Text" in the "Calculation result" dropdown menu, then click the "Storage Options" button and select "Do not store calculation results", then click OK and exit all the dialogs.

              Go to Layout Mode and put the Tag_calc field on your layout. Enlarge the field so that it's big enough to display as many tags as you need.

              If you follow the above steps, it should work.

              (Note: When you enter a new tag in the text field, it won't appear in the Tag_calc field until the window is refreshed. To refresh the window, you can simply navigate to another record, or go to the Records menu > Refresh Window.)

               

              Nick