I have written the following code to read a properties file...........
<b>
public Property(String fileName)
{
try
{
InputStream is = MyClassName.class.getClass().getClassLoader().getResourceAsStream(fileName);
prop.load(is);
is.close();
}
catch (Exception ex)
{
System.out.println("The Exception is: " + ex.getMessage());
ex.printStackTrace();
}
}
</b>
But this code is giving <b> java.lang.NullPointerException </b> at <b> prop.load(is) </b>
please help me....
regards
Brahmachaitanya