Forum Discussion
Former_Member
9 years agoIdeator I
Hi ,
I have tried 2 methods to download file :
Method 1:
I have tried following request :
localhost/.../vaultserver.aspx
But it is not working for vault server .
Method 2:
Now I am trying to send a request to vault server using Java code
HttpPost httpConnection = new HttpPost("">localhost/.../vaultserver.aspx")
HttpClient httpClient = new DefaultHttpClient();
String messageString = "<Item action="get" type="File" id={fileID}> </Item>
httpConnection.addHeader("SOAPACTION", "DownloadFile");
MultipartEntity reqEntity = new MultipartEntity();
reqEntity.addPart("AUTHUSER", new StringBody("admin"));
reqEntity.addPart("DATABASE", new StringBody("InnovatorDemo"));
reqEntity.addPart("SOAPACTION", new StringBody("DownloadFile"));
reqEntity.addPart("XMLdata", new StringBody(messageString));
reqEntity.addPart("AUTHPASSWORD", new StringBody("innovator"));
httpConnection.setEntity(reqEntity);
ResponseHandler<String> response = new BasicResponseHandler();
responseMesaage = httpClient.execute(httpConnection, response);
In this case it gives me following error :
<SOAP-ENV:Envelope xmlns:SOAP-ENV=”schemas.xmlsoap.org/.../”><SOAP-ENV:Body><SOAP-ENV:Fault xmlns:af=”www.aras.com/.../faultcode><faultstring>ProcessApplyItem: Vault Server currently does not support “downloadFile” action of Files</faultstring><detail><af:legacy_detail>ProcessApplyItem: Vault Server currently does not support “downloadFile” action of Files</af:legacy_detail><af:legacy_faultactor /></detail></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>
Thanks for reply !