JavaScript code question

Ask a Question related to Adobe Acrobat Windows, Design and Development.

  1. #1

    Default JavaScript code question

    I have had some trouble with this code. This is the code I used to tie in the street address with the combo box selection:

    var gstreet = new Array

    gstreet["ALB"] = 7601 Bluewater NW
    gstreet["ATL"] = 1800 James Pkwy NW
    gstreet["BUF"] = 1200 William St. Room 100
    gstreet["CHI"] = 7500 W. Roosevelt Rd.
    gstreet["CIN"] = 3055 Crescentville Rd.
    gstreet["DAL"] = 2400 DFW Turnpike
    gstreet["DES"] = 4000 109th St.
    gstreet["DEN"] = 7755 E. 56th Ave.
    gstreet["DET"] = 17500 Oakwood Blvd.
    gstreet["GRE"] = 3701 W. Wendover Ave.
    gstreet["JAC"] = 7415 Commonwealth Ave.
    gstreet["KAN"] = 4900 Speaker Rd.
    gstreet["LOS"] = 5555 Bandin Blvd.
    gstreet["MEM"] = 1921 Elvis Presley Blvd.
    gstreet["MPL"] = 3165 S. Lexington Ave.
    gstreet["NJY"] = 80 County Rd.
    gstreet["OKL"] = 5700 S. Portland
    gstreet["PIT"] = 300 Brush Creek Rd.
    gstreet["PHI"] = 1900 Byberry Rd.
    gstreet["PHO"] = 4949 E Van Buren St.
    gstreet["SAL"] = 1795 West 2100 S
    gstreet["SAN"] = 2501 Rydin Road
    gstreet["SEA"] = 34301 9th Ave. S
    gstreet["SPR"] = 1800 Page Blvd.
    gstreet["STL"] = 5800 Phantom Dr.
    gstreet["ALB"] = 9201 Edgeworth Drive
    gstreet["ALOS"] = 9939 Norwalk Blvd.
    gstreet["ASEA"] = 6215 S. 228th Street
    gstreet["ATEX"] = 1501 South Loop 12
    gstreet["ADAY"] = 53-71 Lau Parkway
    gstreet["ASAN"] = 1099 Whipple Road
    gstreet["ADET"] = 29149 Airport Drive #17
    gstreet["ASPR"] = 41 Lyman Street
    gstreet["ANJY"] = 203 Kuller Road
    gstreet["APHI"] = 321 Jones Blvd.
    gstreet["AMEM"] = 4755-2 Burbank Road
    gstreet["AYOU"] = 100 Eastgate Dr.
    gstreet["AATL"] = 1100 Westlake Pkwy. Ste
    gstreet["AJAC"] = 7469 Kingspointe Pkwy #300
    gstreet["AGRE"] = 1700 Westpointe Dr. Ste. D
    gstreet["AKAN"] = 10810 W 78th Street
    gstreet["ASTL"] = 131 Byassee Dr.
    gstreet["ADEN"] = 11175 East 55th St.
    gstreet["ASAL"] = 5185 Harold Gatty Drive

    I keep getting this error message: SyntaxError: missing ; before statement at line 3. Does anyone have the fix for this problem?
    babycody@adobeforums.com Guest

  2. Similar Questions and Discussions

    1. code hint javascript api
      I am extending dreamweaver to add code hinting and color coding to my proprietary scripting language. I am fine with the Javascript but I am not...
    2. How to use javascript code in a plugin ?
      Hi, I'd like to use javascript in my plugin but after reading the JS API reference, i still don't understand where the code should be placed, and...
    3. Add JavaScript Code to head
      We use a customized button for submitting forms or links at work. The code combines DHTML elements for the look and functionality of the button. ...
    4. JavaScript code hints?
      :confused; I'm a Dreamweaver newbie and would like to get drop-down code hints for JavaScript. Is there a way to enable this option? Thanks much!...
    5. JavaScript Form Code
      Hello, I have a web form that will be processed by formmail.pl. On the redirect page, we would like to use some JavaScript to present the user...
  3. #2

    Default Re: JavaScript code question

    I answered (or at least attempted, my JS is really rusty) in the other thread.
    W_T_Allen@adobeforums.com Guest

  4. #3

    Default Re: JavaScript code question

    you should be assigning a string value to each array element by enclosing the text in "".

    gstreet["ASAL"] = "5185 Harold Gatty Drive"
    Ben_Marchbanks@adobeforums.com Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139