Type mismatch: cannot convert from Object to double
807601May 1 2008 — edited May 4 2008Hi I am using a HashMap and am getting the following problem.
I'm trying to modify an entry in a HashTable by doing the following:
double value = hashmap.get(stringName); // Error here: Type mismatch: cannot convert from Object to double
hashmap.put(stringName, new Double (amount + value)); // amount is a double
Can you someone tell me how I get around this problem.
Thanks