Hi,
I'm having problems retrieving my file. My file is located under "WEB-INF/exportFiles", how to i get that into an inputstream?
I've tried the following
InputStream stream = FacesContext.getCurrentInstance().getExternalContext().getResourceAsStream("/exportFiles/file.pdf");
InputStream stream = FacesContext.getCurrentInstance().getExternalContext().getResourceAsStream("/WEB-INF/exportFiles/file.pdf");
the following does work but id rather have my file in the webinf folder
InputStream stream = this.getClass().getResourceAsStream("/com/pathtothiscode/userguide.pdf");
Any tips would be appreciated, thanks!
/Eric
p:Filedownload file path
-
- Information
-
Who is online
Users browsing this forum: No registered users and 34 guests