on 03-11-2018 2:13 PM
Hi All,
I have a custom business object with attachment node, i want to add an image to the existing attachment folder using webservice (service operation : Update)
i followed the link : https://blogs.sap.com/2015/10/08/read-and-write-bydesign-attachments-using-web-services/ exactly but still an error occurs "key for root node is missing", any help ? below my request sample.. i cant figure out what is missing ?
"<soapenv:Envelope xmlns:soapenv=\"http://www.w3.org/2003/05/soap-envelope\" xmlns:glob=\"http://sap.com/xi/SAPGlobal20/Global\">\n"+ " <soapenv:Body>\n" +
" <glob:JobCardApproveJobcardUpdateRequest_sync>\n" +
" <JobCard>\n" +
" <SAP_UUID>" + jobcardUUID + "</SAP_UUID>\n" +
" <AttachmentFolder DocumentListCompleteTransmissionIndicator=\"false\" ActionCode=\"06\">\n" +
" <UUID>" + attachementFolderUUID + "</UUID>\n" +
" <Document PropertyListCompleteTransmissionIndicator=\"false\" ActionCode=\"01\">\n" +
" <VisibleIndicator>true</VisibleIndicator>\n" +
" <CategoryCode>2</CategoryCode>\n" +
" <TypeCode>10013</TypeCode>\n" +
" <MIMECode>image/png</MIMECode>\n" +
" <Name>" + name + " - After</Name>\n" +
" <FileContent>\n" +
" <BinaryObject>" + imageData + "</BinaryObject>\n" +
" </FileContent>\n" +
" </Document>\n" +
" </AttachmentFolder>\n" +
" </JobCard>\n" +
" </glob:JobCardApproveJobcardUpdateRequest_sync>\n"+ " </soapenv:Body>\n" + "</soapenv:Envelope>";
solved, i needed to add action code 01 in the filecontent tag
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Haitham,
Please try using the action code "04" as suggested in the blog and make sure you pass the UUIDs.
Thanks & Regards,
Meghna
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
81 | |
24 | |
11 | |
9 | |
7 | |
5 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.