Hi,
I have the following :
// setObj is a TreeSet and elems and elems2 are ArrayLists (both seem to be set up fine - a.k.a used elsewhere but elems and elems2 are Arrays
for (int i = 0; i <= currItem; i++) {
setObj.add(new Object[] { (
String)elems.get(i), new Double(Double.parseDouble(elems2.get(i))) });
}
// With the above I get the following error
The method parseDouble(String) in the type Double is not applicable for the arguments (Object)
// When I try to cast the value inside the parseDOuble method I get the following
java.lang.ClassCastException: [Ljava.lang.String;
How can I use the ArrayLists in this method? Some sort of casting I need to do or something along those lines? Thanks in advance for any help.
Rob