[Fwd: Question]

Walter Vaughan wvaughan at steelerubber.com
Mon Aug 2 17:07:54 PDT 2004


Reformatted for the HTML mail impaired...

-------- Original Message --------
Subject: 	Question
Date: 	Mon, 2 Aug 2004 19:54:19 -0400
From: 	George Simon <flowersoft at compuserve.com>
Reply-To: 	George Simon <flowersoft at compuserve.com>
To: 	Filepro 2 List <filepro-list at nospam.celestial.com>



Today I came across something I did not know.
I have a zip code file of US and Canadian zips in a filePro database.
Index A is build on the zip code field and the city field.
I'm doing a lookup into it using the zip code only.  If I find a match,
I do a getnext and if it is the same zip code but to a different city, I
display a browse window with all the cities matching the zip code, for
the user to choose from.  This works fine.

However, if there is already something in the city and zip code fields,
I wanted to display the same browse window but with the highlight on the
record matching the city.  To acomplish this I was stuffing a dummy
field with the contents of the zip & city fields like: ky=77&75
and doing the lookup.  In order not to display zip codes that did not
match, I put a match length of 7 (the length of the zip code field) in
the browse lookup.  To my surprise, the highlight always falls on the
first record of the browse window, even though doing an errorbox of the
ky dummy just prior to the lookup, shows that it contains the zip code
and city.  Changing the position of the first record to middle or bottom
has no effect, the highlight bar is always on the first record matching
the zip code.  Is this because I put a match length of 7 on the lookup
or should it work the way I thought it would?




More information about the Filepro-list mailing list