What you want to be be used for the QuoteNum field is an expression using the column from your UD table that the DMT updates in order to force a new autoprint. Off the top of my head something like
Then your DMT file would be
Company Key1 Number01
MC EXPORT 12345
MC EXPORT 12346
MC EXPORT 12350
Make sure that you use Update mode in DMT. You might need to first create that UD04 record with Key1=‘EXPORT’, in order for updates to work. If so, just make a DMT file with just the first row, and processes with the Add box checked.
Here’s how I think it would go:
- DMT updates the UD04 table. Just the record where Key1 = ‘EXPORT’, with the Number01 being set to 12345.
- The UD04.Update BPM is triggered.
- The AutoPrint widget fires, using UD04.Number01 (12345) as the QuoteNum to print.
the above are repeated for rows 2 and 3 of the DMT for quotes 12346 and 12350.
One thing you need to be clear on is that this makes a separate task for each quote. You’ll get a separate printout (or emailed PDF) for each quote. So you’ll need a way to manage them.
What I would do is make a Break Route that emails the quote to me, setting the Attachment’s name to the QuoteNum. Like:
QUOTE-<quotenum>. Make the subject line something specific to identify these emails. Make a rule or script in Outlook that automatically saves the attachment for any received email that has that special subject line.
You’ll still end up with an individual PDF for each quote, but they’d be autmatically named and saved in a specific location.
Some things I missed…
In the “Set up Auto Print” dialog, set
SSRSEnableRouting to true. If you go with the break/route idea of emailing them to yourself.
No Regen is required when using UD tables - unless you add a column to it. Some folks prefer to add columns so they have meaning fulnames, instead of just relaying on Number01 meaning QuoteNum.