Jump to content

File Path On Linux Host


thakurs

Recommended Posts

i want to give the path of files which are using in servlet but it is giving me error (java.lang.NullPointerException) bcoz of invalid path
plz help me out with the path
Here is MyCode
:=
public static Document getDOM(String test) throws SAXException,ParserConfigurationException,IOException, URISyntaxException
{
Document dom=null;
File quizFile=null;
quizFile=new File("/home/thakurs/public_html/"+test+"-quiz-1.xml");
System.out.println("Quiz File Absolute Path "+quizFile.getAbsolutePath());

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...