Opening/reading a file from a Struts application...

2003-07-29 Thread Davide Bruzzone
Greetings all... I'm trying to load and read a text file (on the server's filesystem) from within a Struts application. I'd like to be able to put the file in the WEB-INF, or the WEB-INF/classes directory, but am having trouble finding the file (i.e. I'm having trouble obtaining the path that I

RE: Opening/reading a file from a Struts application...

2003-07-29 Thread Jarnot Voytek Contr AU HQ/SC
/reading a file from a Struts application... Greetings all... I'm trying to load and read a text file (on the server's filesystem) from within a Struts application. I'd like to be able to put the file in the WEB-INF, or the WEB-INF/classes directory, but am having trouble finding the file

RE: Opening/reading a file from a Struts application...

2003-07-29 Thread Davide Bruzzone
Thank you... I'll give it a try... Cheers... Dave -Original Message- From: Jarnot Voytek Contr AU HQ/SC [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 29, 2003 12:02 PM To: 'Struts Users Mailing List' Subject: RE: Opening/reading a file from a Struts application... -Original

Re: Opening/reading a file from a Struts application...

2003-07-29 Thread Craig R. McClanahan
On Tue, 29 Jul 2003, Davide Bruzzone wrote: Date: Tue, 29 Jul 2003 11:57:41 -0600 From: Davide Bruzzone [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Opening/reading a file from a Struts application

RE: Opening/reading a file from a Struts application...

2003-07-29 Thread Dolf Starreveld
: Opening/reading a file from a Struts application... -Original Message- From: Jarnot Voytek Contr AU HQ/SC Sent: Friday, June 27, 2003 11:53 AM To: 'Struts Users Mailing List' Subject: RE: getting a file path to /WEB-INF from a HttpSession try request.getSession(false).getServletContext

RE: Opening/reading a file from a Struts application...

2003-07-29 Thread Vijay Balakrishnan
Mailing List Subject: Re: Opening/reading a file from a Struts application... On Tue, 29 Jul 2003, Davide Bruzzone wrote: Date: Tue, 29 Jul 2003 11:57:41 -0600 From: Davide Bruzzone [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL

Re: Opening/reading a file from a Struts application...

2003-07-29 Thread Stephan Wiesner
You can load Properties files like this: java.io.InputStream in = baseClass.getResourceAsStream(fileName); Properties props = new Properties(); props.load(in); I use this with my base classes, as the have to work outside my Tomcat, too, that's what base classes for, after all. Have