Test <test (AT) 123 (DOT) com> wrote:
Quote:
how to script a button to move users to
records with specific initials of last names in found set of records.
for example being able to hop from the 'c's to the 'm's or the 'w's
within the found set of records. |
Assuming you have a field NameLast, you can do a search for NameLast =
w. The new found set will include all records where a last Name starts
with a w.
If you need to keep the found set as it is, you could sort it and then
loop through until you find a record where NameLast starts with w. The
script would look like this:
Sort
Go To Record (first)
Loop
Exit Loop If Name Last starts with w
Go To Next record (exit after last)
End Loop
If there are many records, the loop will be slow. I'd rather do the
search.
You could also use an auto relation: Make a global field for the letter
you need and a calc field finding the first letter for NameLast. Place
two occurences of the same table on the relation tableau and create a
relation based on those two fields.
Now you put your favourite letter in the global field and use "go to
related records" or show the related records in a portal.
Keep in mind that the name "de Wit" will be found if you search for d or
w. If you use the first letter relation, it will only be found under d.
--
http://clk.ch