File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes How to create file on webserver Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Groovy Fundamentals video training course this week in the Groovy forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "How to create file on webserver" Watch "How to create file on webserver" New topic

How to create file on webserver

Ajit Kanada
Ranch Hand

Joined: Jan 23, 2001
Posts: 95
I m using servlet to create xml file.How can create the file on the server
I m using javawebserver..i tried with following code
pw = new PrintWriter(new PrintStream(new FileOutputStream("/javaWebServer2.0/ajit.xml")));
but i m getting following error
CreateXML is my class..[CreateXML.<init>]: cannot access file /javaWebServer2.0/ajit.xml
can somebody help me
thanx in advance

I agree. Here's the link:
subject: How to create file on webserver