How can you DMT attachments?

Looking to see if oyou can DMT attachments for the Sales Order Hed and details records?

Hey Rick,

You’re looking to programmatically add attachments, right? @josecgomez had a nice demo of a dashboard his company did for remote workers.

Epicor attachments are done in two steps:

  1. Identify the document
  2. Link the document

The first you DMT with Ext File Ref

The second you choose the object you want to attach to

As with any DMT, do it by hand and check out what fields are used and how. But that’s it. Where things get interesting depends on where the actual document is… That’s why I like Jose’s solution over using DMT.

1 Like

@Mark_Wonsil - When using DMT to make add new records that are typically automatically numbered (Quotes, Orders, etc…), should the DMT file always specify 0 in that field?

For example, your first screen shot shows:

Should the DMT file have zeros in column XFileRefNum ?

If you do create your own numbers are they just ignored?

This can be REALLY important when doing a two step DMT like you mentioned. Specifically because the second DMT needs the XFileRefNum that the system ended up using - which might not match the numbers your 2nd DMT file is using.

So you really need to export the results of the first DMT, to make sure your XfileRefNums in the second DMT file match.

I said you could do it. I didn’t say it was easy. I thought I threw significant shade on the idea but I enjoyed yours too. :smirk:

When my company made changes for NIST 800-171 we had to rearrange the folder structure. I used DMT to rename all of the locations where the documents were stored. What a time saver.

1 Like

DMT_CycleCount.baq (20.1 KB)

I see that this BAQ that I made (which I thought was uploaded)

This BAQ pulls out the folders I think you are looking for.

@Mark_Wonsil, can you direct us to the @josecgomez demo that you’re referring to?
@josecgomez has a LOT of postings to sift through :grimacing:.

I believe this was it.

Code from MEUG Presentation on 5/20/2020 (Customization Tips and Tricks) - Code Review / Sharing - Epicor User Help Forum (

Thanks very much @Mark_Wonsil!