You need to sign in to do that
Don't have an account?

Trigger to copy attachment from case to custom object on the case
Hi,
I need a trigger that clones an attachment created on a case to the most recently created custom object on that case.
In other words, let's say I have the case object. Let's say I have 1 custom object on the case object. When a case is created or updated with a new attachment on it, I need that attachment to be put on that custom object as well as the attachment.
Use case:
Case is created or updated with an attachment on it. That attachment should now be automatically added to the custom object "x", not just the case.
I'm working on this but not sure how to get it to work. I'm thinking the trigger ought to be on the attachment object since that is where the action is happening to trigger everything.
Does anyone have any ideas?
I need a trigger that clones an attachment created on a case to the most recently created custom object on that case.
In other words, let's say I have the case object. Let's say I have 1 custom object on the case object. When a case is created or updated with a new attachment on it, I need that attachment to be put on that custom object as well as the attachment.
Use case:
Case is created or updated with an attachment on it. That attachment should now be automatically added to the custom object "x", not just the case.
I'm working on this but not sure how to get it to work. I'm thinking the trigger ought to be on the attachment object since that is where the action is happening to trigger everything.
Does anyone have any ideas?
Hope it will help.