SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Member
    Join Date
    Jun 2006
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Error :plz help,Unterminated String Constant

    hey all,
    iam using a javscript function in which iam passing values which are entered in a form(In my form i have text fields,text area,Date & time Fields)
    Some times its working fine but then some times its giving error as
    Code:
    Unterminated String Constant.
    Its showing a large line no.i cannot make out the error from it.
    Iam not entering anyspecial charaters.


    my code goes this way

    Code:
    String	passVal="\"rowSelected('"+a16.get(j)+"','"+a17.get(j)+"','"+a18.get(j)+"','"+a1.get(j)+"','"+a8.get(j)+"','"+a3.get(j)+"','"+a5.get(j)+"','"+a11.get(j)+"','"+a4.get(j)+"','"+dt+"','"+a6.get(j)+"','"+a7.get(j)+"','"+a13.get(j)+"','"+a12Re.get(j)+"','"+a14.get(j)+"','"+a15.get(j)+"','"+a12.get(j)+"')\"";
    
    <tr onClick=<%= passVal %>>
    Can someone help me?

  2. #2
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    So it seems like your passVal has either double or single quotes in it. Therefore the uterminated String Constant error


Bookmarks

Posting Permissions

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