File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSF and the fly likes Null pointer exception on facesContext Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "Null pointer exception on facesContext" Watch "Null pointer exception on facesContext" New topic
Author

Null pointer exception on facesContext

sigamala viswanath
Greenhorn

Joined: Mar 13, 2006
Posts: 26
Hi,
FacesContext facesContext = FacesContext.getCurrentInstance();
ResponseWriter writer = facesContext.getResponseWriter();

Above Code writer is value Null.

facescontext = com.sun.faces.context.FacesContextImpl@30543054
facesContext.getResponseWriter() = null

Can any body help me why its null wht the issue.


Thanks,
Viswanath
sigamala viswanath
Greenhorn

Joined: Mar 13, 2006
Posts: 26
Any one to help me ...
sigamala viswanath
Greenhorn

Joined: Mar 13, 2006
Posts: 26
Any idea on Above question ?

Thanks,
Viswanath
ramu prabakaran
Greenhorn

Joined: Mar 20, 2006
Posts: 9
Verify your web.xml and faces-config.xml files.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Null pointer exception on facesContext