Help when emailing attached Doc to be named based on Custom Field

Hi all,
We have added a Custom field on Sales Invoice DOC_AGT.
I have managed to when user click Email the Subject to be if Submitted to be like SALES INVOICE: DOC_AGT (content).

But now need help on the Attached form based on the Print_format to use same Name.

I have also managed to when user do PRINT and PDF the name (if Sales Invoice is Submitted) to be based on the DOC_AGT content but when Emailing it does not call the same download_pdf from Utils.Print_format!