Results 1 to 2 of 2
  1. #1
    moaxjlou is offline Member
    Join Date
    Oct 2008
    Rep Power

    Default String to Object conversion

    I am trying to add a String into an arrayList using the add() method. The problem is, add() only accept Object as the parameters.

    Does anybody know how to convert String into Object?

  2. #2
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Blog Entries
    Rep Power


    A String is an Object. Are you getting an error when you try this? If so, post the code and the error message.

Similar Threads

  1. String to Integer Conversion in JSP
    By vinikz in forum New To Java
    Replies: 8
    Last Post: 11-10-2010, 02:45 PM
  2. string conversion??
    By j2vdk in forum New To Java
    Replies: 13
    Last Post: 09-19-2008, 03:35 PM
  3. bytearray to string conversion
    By mew in forum New To Java
    Replies: 1
    Last Post: 01-28-2008, 10:39 AM
  4. Method for String to int conversion
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 01-02-2008, 06:35 PM
  5. String to Date conversion
    By javaplus in forum New To Java
    Replies: 2
    Last Post: 11-06-2007, 07:16 PM

Posting Permissions

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