|
|
| Doubts regarding Hashtable |
Expert:Sylvia
Hi, I am new to hashtable.Is it possible to create a hashtable like this? java.util.Hashtable hashtable=new java.util.Hashtable(); hashtable.put(new RowObject("100","100"),new RowDetails(12,13,10,1));
since we get the key of hashtable from the database. When I tried to retrieve using hashtable.get(new RowObject("100","100"));
a null pointer exception is occuring.
Kindly reply for this
thanks Sylvia |
| Answers |
Hi friend,
new RowObject("100","100")
if your is constructor then a constructor is no return any value. so your example is occuring a null pointer exception.
--------------------------------------------------
Read for more information,
http://www.roseindia.net/java/example/java/util/
Thanks.
|
| More Questions |
|
|
Post Answers
Ask Question
Facing Programming Problem?
|
|
|
|
|