Hi vilas,
I think that I didn't understand the problem, if you saved your attachment, you just need associate the value of the key of Attachments2 object to the property AttachmentEntry in the Delivery object. But this property "AttachmentEntry " is only available in version 9.0 or latest from SAPBobsCom.
Your code that you past in the last answer works fine if you use a newly SAPBobsCom.
With your code, I get this result in my sap b1 client:
Regards,
Diego