BPM on Attachments

I am trying to create a BPM on attachments. I have created a Pre-Processing record on XFileRef.Update. I want to prevent users from adding shortcuts as attachments. I cannot seem to get the BPM to work with any type of conditional I use.

Has anyone been able to do something like this?


Try a data directive the attachments stuff is tricky and I don’t think it uses the same BO for everything. Try a DD in XFileAttach or XFileRef

I have a BPM that checks to see if it’s a local drive or a mapped drive, it’s an In-Transaction Data Directive on XFileRef, seems to work for us. Here’s a screenshot of the setup, maybe you can tweak it to check for shortcuts files.


You should check for the file extension. Windows 7 shortcut files have the .lnk extension.

1 Like

I got it to show a message. I used an In-transition data directive. But it still allows the user to attach the file, after clicking OK. How do i stop the attachment?


I needed “Show Message” to be “Raise Exception”

1 Like

You need use the Raise an Exception to flow control to abort the current code block and exit from the BPM.

This is a code controlled example:
if(lastUnderScore + 1 == PartNum.Length)
throw new Ice.BLException(“Add manufacturer to end of part number”);

1 Like

The show message flow does not provide you with control. Use the Rise Exception to Display a message and abort the flow.