about string buffer

hi i have one problem in stringbuffer please anyone solve this problem here my code is there about the stringbuffer

StringBuffer=msg=null;

msg.append("Your leave has been successfully sanction from");

msg.append( " "+starttime[j-1]+" To "+endtime[j-1]+" ");

after that i have passing msg value in one function

s.send("mail.localhost.com",to_emailid," "+(String)session.getAttribute("userId")+" ","About the leave",msg.toString());

so its throwing null pointer exception lang exception please solve that problem why its show null pointer exception

[593 byte] By [abhinay_31a] at [2007-11-27 10:11:48]
# 1

You seem to be confused about some basic Java programming skills.

If you want to use a StringBuffer, you have to instantiate one:

StringBuffer msg = new StringBuffer();

bshannona at 2007-7-28 15:16:04 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...