Trigger Print Preview after MtlTags form is opened

I believe the following code is the key to getting this to work:

varReport.SubmitToAgent(varDS, “SystemTaskAgent”, 0, 0, Erp.UIRpt.MtlTags);

The trouble I am having is defining “varReport” and “varDS”. I have read through the following threads, but am still stuck.

The above threads all involve setting the report parameters from scratch. Since the MtlTags form has already loaded with the parameters/dataset needed to run the report (except for the correct ReportStyleNum, which can be set with a DataView), it should just be a matter of calling those stored parameters for SubmitToAgent?