Hi,
I'm trying to save an interactive form on the hard disk of my pc using web dynpro for java
To save the form, I created the following code :
boolean ok = true;
// get date of today
byte[] bytes = wdContext.currentContextElement().getPdfSource();
try
{
File file = new File("C:
form.pdf");
FileOutputStream os = new FileOutputStream(wdContext.currentContextElement().getFile());
os.write(bytes);
os.close();
wdContext.currentDataSourceElement().setApproverComments("ok" + bytes.length);
}
catch (IOException e)
{
// e.printStackTrace();
wdContext.currentDataSourceElement().setApproverComments(e.toString()+ bytes.length);
* ok = false;*
}
return ok;
With this code, I don't receieve any error message but can't find the file on my hard disk.
Do you know where the problem could come from?
Thanks a lot for your help
Karim