Skip to Main Content

New to Java

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Newbie Doubt regarding Array and ArrayList

843789Dec 26 2009 — edited Dec 27 2009
I have a Method :
public void setCells(ArrayList<String> loc)
Which i need to call using :
string[] locations = {"1","2","3"};
example.setCells(locations);
But i'm not able to pass the String array to the array list.
How can i solve this problem ?

Thanks
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 24 2010
Added on Dec 26 2009
9 comments
151 views