Re: A "How would you do this" type of question.



Korto wrote:
Imagine you are writing a program that will display a map of the United

States. Your program will ask a user to input their ZIP code. Once
they do, a dot will appear on the map to indicate where that ZIP code
is located.

My question is, how would you go about doing something like this, in
general?
Would you have a file of all ZIP codes and their longitude, latitude
coords and extrapolate those to x,y coords on your graphic map? Or, is

there an easier way?

Thanks,
Korto

No. But it's easy to get the complete list of zip codes and
corresponding lat-lon coordinates in a flat file for a few dollars from
one of several web sites. You can sort this on zip and use binary
search to find any zip very quickly. Plotting lat-lons on a map
requires the same projection transformation used for the map. It's
tedious to get all the details of this right. But it's already done
for you, at least in Perl. See
http://search.cpan.org/~lgoddard/Image-Maps-Plot-FromLatLong-0.12/FromLatLong.pm
..

An example of a map done this way is

http://bridgecontest.usma.edu/reports/teammap_small.png

All the best,
Gene

.



Relevant Pages

  • Re: I get Object reference not set to an instance of an object in a simple application
    ... One flatFile csv text file as input and a flatfile schema for this csv ... One example of how xml output should look like and generate a schema ... I have created a Map between the OpenSourceSchema and the ... OpenSourceSchema is the schema for the csv flat file. ...
    (microsoft.public.biztalk.general)
  • Re: Send Pipeline processing problem
    ... The send port map is applied before the message hits the pipeline. ... The pre-assemble stage receives the mapped message. ... flat file as the output so i add a Flat file assembler on to the ...
    (microsoft.public.biztalk.general)
  • Re: Send Pipeline processing problem
    ... is configured on the Pre-Assemble stage of the Send pipeline. ... flat file as the output so i add a Flat file assembler on to the ... Assemble stage of my send pipeline.There is a Map on the send port. ...
    (microsoft.public.biztalk.general)
  • RE: The Root Element Is [Still] Missing
    ... Is this the schema you recently added the namespace to? ... I have seen that error before when I was trying to validate a flat file ... I do not think that would allow you to map the data since the ... we can't get past the send pipeline. ...
    (microsoft.public.biztalk.general)
  • RE: Newbie Flat File Schema question
    ... There is no way of telling the flat file parser to ignore data, ... use a map to eliminate unwanted data. ... >>Then I made a child record which is positional with two child field ...
    (microsoft.public.biztalk.general)