Another Usefull Hyperlink


[ Follow Ups ] [ Post Followup ] [ Signature.net Forum ]

Posted by Herb Walters on March 22, 2004 at 12:02:22:

Just thought would pass along another usefull way of using hyperlinks. Seems keep finding new ways of using them.

In D/PAC customer maintenance, inquiry, and vendor maintenance. Added a link "Display Map". When clicked, Mapquest.com is launched with the address and the map is automatically displayed.

Below is the linked that is built and the code I used that did it.

http://www.mapquest.com/maps/map.adp?country=US&Countryid=250&addtohistory=&address=2202+REDMOND+ROAD&city=JACKSONVILLE&state=AR&zipcode=72076&submit=GET+MAP

373000 GETEVENT:
374000 !
375000 STREET$=STRIP(CADR2$)
376010 L=LEN(STREET$)
376030 IF L=0 OR POS('SUITE',STREET$) NE 0 OR POS('BOX',STREET$) NE 0 THEN
376040 STREET$=STRIP(CADR1$)
376050 L=LEN(STREET$)
376060 ENDIF
376070 !
377000 FOR LOOP=1 TO L
378000 E=POS(' ',STREET$)
380000 IF E NE 0 STREET$=SUB(STREET$,1,E-1)+'+'+SUB(STREET$,E+1,L-E)
380010 NEXT LOOP
380020 !
380030 CITY$=STRIP(CCITY$)
380040 L=LEN(CITY$)
380050 !
380060 FOR LOOP=1 TO L
380070 E=POS(' ',CITY$)
380090 IF E NE 0 CITY$=SUB(CITY$,1,E-1)+'+'+SUB(CITY$,E+1,L-E)
380100 NEXT LOOP
380110 !
380120 STATE$=SUB(CSTATE$,1,2)
380130 !
380140 ZIP$=SUB(CZIP$,1,5)
380150 !
381000 SELECT CASE EVENT$
382000 !
383000 CASE "LINK1"
384000 DOCPATH$='http://www.mapquest.com/maps/map.adp?country=US&'
385000 DOCPATH$=DOCPATH$+'Countryid=250&addtohistory=&address='
385010 DOCPATH$=DOCPATH$+STREET$+'&city='+CITY$+'&state='+STATE$
385020 DOCPATH$=DOCPATH$+'&zipcode='+ZIP$+'&submit=GET+MAP'
385030 PRINT (0) (LAUNCH=DOCPATH$)
385040 INPUT (0) VALIDATE$
385050 !
385060 ENDSELECT
385070 !
385080 EVENTSUB GETEVENT EVENT$ SOURCE$
385090 !
385100 RETURN
385110 !


Follow Ups:



Post a Followup

Name:
E-Mail:

Subject:

What is the name of the main Signature System's Product?

Comments:

Optional Link URL:
Link Title:
Optional Image URL:

You may attach up to 5 files to your followup (see below):






[ Follow Ups ] [ Post Followup ] [ Signature.net Forum ]