Differences between revisions 1 and 2
Revision 1 as of 2005-01-11 10:42:23
Size: 593
Comment: Importing old wiki ...
Revision 2 as of 2009-09-20 22:47:37
Size: 593
Editor: localhost
Comment: converted to 1.6 markup
No differences found!

Q: How do I specify where attachments are written?

A: Just write the output yourself, for example:

   Iterator       iterator = call.getResponseMessage().getAttachments(); 
   AttachmentPart part     = (AttachmentPart) iterator.next(); 
   DataHandler    dh       = part.getDataHandler(); 

   dh.writeTo(new java.io.FileOutputStream("completeFilePathWhereYouWantTheFileWrittenTo")); 

or force Axis to generate the temp file and move it around your file system:

    new java.io.File(dh.getName()).renameTo("TheFileYouReallyWant"); 

FrontPage/Axis/AttachmentsSpecifyFilename (last edited 2009-09-20 22:47:37 by localhost)