Question
Estes Forwarding Worldwide
US
Last activity: 19 Jul 2023 12:20 EDT
Attach PDF to multiple cases
Is there a way to attach a single PDF to multiple work objects? Or does each attachment correspond only to a single object?
Thanks! Devin
-
Reply
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Accepted Solution
Updated: 27 Feb 2023 11:15 EST
Bits in Glass
IN
to answer your question the attachment will be stored in table mapped to Data-WorkAttach-File and link between case and this table willl be mainted in Link-Attachment. so technically you need to create one Link-Attachment instance for every case case you are having whereas only pdf(Data-WorkAttach-File) should suffice.
Also, you can explore Space Functionality
collaborating-shared-content-using-documents
Hope this answers your question.
If yes, kindly do accept the solution. if you need more details happy to help.
Updated: 24 Feb 2023 22:33 EST
Virtusa
IN
@DevinD16607791 hey
If you want to attach using an activity, try below steps
1. Create a pagelist suppose WorkObject.pxResults which will have all the pzInsKey s of multiple objects
2. Create pyNewFileAttachment page and populate initial data like pxAttachKey, pyNote, pxAttachName, pyAttachStream, pyUploadedFileName, pyCategory, pxCreateOpName etc.., (Some of them will be populated automatically when u save the pyNewFileAttachment page.)
3. Now loop through the Work object.pxResults and open each work object on to a temp page supposed TempWorkObject using obj-open by handle.
4. In the loop, Now set pxRefObjectKey property on pyNewFileAttachment page as pzInsKey of the opened work object and do Obj-Save on pyNewFileAttachment page.
5. Use Link-Objects method on TempWorkObject page and pass pyNewFileAttachment page to this method.
6. Finally perform commit out side the loop and remove WorkObject, TempWorkObject and pyNewFileAttachment pages using Page-Remove method.
I didn't implemented this, but I hope it should work :)
Estes Forwarding Worldwide
US
@BATTINIRAMESH Thank you for your response! This seems like a viable solution, but wouldn't performing an Obj-Save on pyNewFileAttachment for each case create multiple Data-WorkAttach-File? Wouldn't this be an undesired behavior when one would suffice?
Accepted Solution
Updated: 27 Feb 2023 11:15 EST
Bits in Glass
IN
to answer your question the attachment will be stored in table mapped to Data-WorkAttach-File and link between case and this table willl be mainted in Link-Attachment. so technically you need to create one Link-Attachment instance for every case case you are having whereas only pdf(Data-WorkAttach-File) should suffice.
Also, you can explore Space Functionality
collaborating-shared-content-using-documents
Hope this answers your question.
If yes, kindly do accept the solution. if you need more details happy to help.
Bits in Glass
IN
@DevinD16607791 You have 2 ways to do this:-
1. If you want to fetch attachments of a case(eg:- C-1) and you want to display it in other cases(C-2.C-3,C-4) and if you have C-1 value in the other cases, you can use D_AttachmentsList dpage or D_AttachmentsListByCategory. This is pulling method.
2. If you want to push attachments from C-1 to other cases, use pxLinkAttachmentTocase activity(if multiple attachments loop pyAttachments and call this activity). You dont have to anything else, just call this activity create a link to the other cases with the file.
Perficient
US
Just wanted to follow up and see how you implemented the solution?
Thanks in advance!