cancel
Showing results for 
Search instead for 
Did you mean: 

Save Attachments of Activity also on the Customer?

Former Member
0 Kudos

Hello Friends,

Is it possible to store the Attachments of an Activity (created in WebUi) also to the Customer (for whom we create the Activity?)

Thanks for helping...

PS: I know the function for "helpful answers" here in SDN... (if you create a helpful answer)

Accepted Solutions (0)

Answers (1)

Answers (1)

stephenjohannes
Active Contributor
0 Kudos

Chris,

Sure, but not automatically. You would have to code an extension to store the document to be associated with both the customer and activity transaction in question.

For the general guts on how documents are stored in CRM I would recomend a search on the class

CL_CRM_DOCUMENTS in SCN to get some general background. Lots of threads on this class.

The only problem now is that when you "attach" an automatic commit takes place in the document storage outside of the business transaction. You could however use the CRMV_EVENT framework to transfer the document from the transaction to the customer upon saving of the activity and it shoudl not be too difficult.

Not sure though if that will meet your business requirements. My guess it will probably be a lot more difficult to "transfer/synch" the documents when they are attached to the business transaction, feasible but I really wouldn't want to code that solution.

Take care,

Stephen

Former Member
0 Kudos

Hello Stephen,

Thanks for your answer. I was a bit confused about your last sentence...

>>My guess it will probably be a lot more difficult to "transfer/synch" the documents when they are attached to the business >>transaction, feasible but I really wouldn't want to code that solution.

Do I understand you right, that you would not recommend such a solution? (Automatically attach the documents?)

The first part of your message sounded very optimistic.

-F.Y.I.- (no question) ---

My business request is...

The old CRM System showed the documents (from Activities) directly on the BP Employee and BP Customer. So guess what is the "worst thing in SAP CRM". Users are not finding there documents anymore.

However - I have to write another datamigration report (to attach the already created documents to BP EMP and BP CUST of the activities). Maybe I can reuse this Report as a Batch Job. (To catch also future Attachments and append them to BP EMP and BP CUST)

Again... Thanks four your help... if you have another idea this would be a great thing...

Best regards

Chris

stephenjohannes
Active Contributor
0 Kudos

Chris,

The problem is that there aren't many exits in the document management framework. Now that being said, you could look at the UI component that attaches the document and see if you could manipulate it so that as you submit the attachment to the transaction it will submit the attachment to the partner. The problem is that the attachments are "committed" outside of the LUW for the business transaction(reason why you don't have to hit the save button to save an attachment once attached).

So your other option was my first choice, which will be a close approximation, is that whenver the transaction is saved, you can transfer the attachments over. This of course means a user could attach something and not "save" the transaction and you would not get the synch. That would be the problem, so the more difficult and correct approach is hacking the attachment UI component to accomplish this. I would give it a 75% chance of feasibility, and something that would take me personally a week to get working at least.

So if you do figure this out, or get stuck along the way as you go into the details, please post back here or open a new thread either way. I can take a look provided you give a specific area that you want to look. The only thing I ask is we post the final solution in the CRM wiki once solved.

So your first tasks is to anlalyze the component view GS_CM/AddDoc to find the insert point and where the BO reference is set for the document being attached.

Take care,

Stephen

Former Member
0 Kudos

Hi,

we stopped investigating in this area since our WebUI Development System is getting pretty slow after attaching so many documents.

Anyway - thanks for your help.

Regards

Chris