In future, while posting code, please UseCodeTags I have added them this time for you. As you can see the tags make the code much more easy to read and understand
gaurav doshi wrote:Dear Manish,
Thanks for reply.I know that ctx1 is null but I want to know that why it is coming null I mean what could be the cause behind that.
What's the "uripath" value you are passing?
Also from the API docs
In a security conscious environment, the servlet container may return null for a given URL.