permaculture playing cards*
The moose likes Java in General and the fly likes Error while reading Key/ value pair fromprops from props file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » Java in General
Bookmark "Error while reading Key/ value pair fromprops from props file" Watch "Error while reading Key/ value pair fromprops from props file" New topic
Author

Error while reading Key/ value pair fromprops from props file

Srinivasa Kadiyala
Ranch Hand

Joined: Jun 10, 2004
Posts: 237
I am pulling the informatiom from a props file. Using

MessageResource props=MessageResources.getMessageResources("resources.ApplicationResources");
props.getMessage("key");

Some times it is fine and some times the code is not pulling the value and throwing null value and subsequently nul pointer exception.
Using IE 6.0.


Srini
Annie Smith
Ranch Hand

Joined: Mar 05, 2005
Posts: 172
Is this question related to JDBC?!?

Besides, it is not even descriptive enough. But as a suggestion, you should be having a null check.


Cheers!<br /><b>Annie</b>
Srinivasa Kadiyala
Ranch Hand

Joined: Jun 10, 2004
Posts: 237
sorry to all seeing JDBC area.... I posted here by mistake. Request the concerned to move to Java(Intermediate) area.

I will check for null and already implemented that.

my question is that why it is getting null some times only?

Thanks in advance
Annie Smith
Ranch Hand

Joined: Mar 05, 2005
Posts: 172
Originally posted by Puthriah Sarma:

my question is that why it is getting null some times only?


Like I already mentioned, your post is not descriptive enough. Are you using a web application or a standalone one? ...
Srinivasa Kadiyala
Ranch Hand

Joined: Jun 10, 2004
Posts: 237
Hi Annie

I am using a web application and using IE 6.0, Tomcat 4.1,
Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 30595
    
154

Moving as requested


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Error while reading Key/ value pair fromprops from props file