I'm using Tomcat 8.
Writing to an absolute path (even outside of the application) works well:
fos = new FileOutputStream("/home/XXX/file1.jpg");Therefore I assumed that it should be possible inside of the application, too. I thought my problem is to correctly figure out the relative path. Am 03.02.2016 um 13:29 schrieb Ernesto Reinaldo Barreiro: > Maybe I'm mistaken but I doubt in some application servers you might be > able to do that > > On Wed, Feb 3, 2016 at 1:27 PM, Karl-Heinz Golz <[email protected] >> wrote: >> Hi, >> sorry for my simple question. I have already wasted some time but it >> seems I have a blackout >> and therefore I want to ask you. >> >> I need to write files to a folder XXX relative to the application classes: >> >> XXX >> StartApplication.java >> HomePage.java >> HomePage.html >> ... >> >> The question is ??? in: >> FileOutputStream fos = new FileOutputStream (???); >> >> many thanks in advance >> Karl-Heinz >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> >> > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
