Hello and welcome to our community! Is this your first visit?
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Aug 2010
    Thanked 0 Times in 0 Posts

    Unhappy parsing a response object that contains string array.

    Hello All,

    I have a string array in a class file that contains 5 values, which I need to display on the jsp page.

    but when I send it to the javascript it prints [Ljava.lang.String;@104f8b8 .

    what do i do about it. I am a new to javascript.

    Is there a way to get my array data from the response object.

    Please help.

  2. #2
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Thanked 4,947 Times in 4,908 Posts
    Nothing to do with JavaScript, per se.

    The fault is in your Java code.

    You *MUST* send that array as *TEXT*. That is, you will have to write Java code to convert the array into a form that JavaScript can understand.

    You can *NOT* depend on Java to do the conversion for you. As you can see, it tries to convert the array to a standara Java serialized format, which nothing but Java will ever understand.
    Be yourself. No one else is as qualified.


Posting Permissions

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