Add % to AR Invoice

We are looking for a way to add a 3% Miscellaneous amount to our invoices automatically. Hoping there is some code for a BPM but any other way to accomplish would be great. So in short if we have an invoice for $100 we would see an invoice for $100 plus a miscellaneous charge for $3 for a total of $103

What version are you on specifically?
This is tagged as E10 but your profile says 9.05.

Is this applicable irrespective of invoice amount or for minimum order value ? If its for all invoices, then you should consider using tax by mapping to misc. charge GL account. If its for minimum order value, then add Misc. Charges by using BPM/customisation in Sales Order Entry when Ready To Process flag is ticked

We are on version 10.2.400. I have updated my profile.

This is applicable regardless of amount. For each invoice we want to add 3% of the total in a miscellaneous charge. A BPM would be nice so we could turn it on and then turn it off as I do not expect this to last more than a few months. The additional charge is due to increased costs in overtime to make product until the workforce availability opens back up.

Here is an idea I would try:
In 10.2 with Data Directives you can call another BO Method when an Invoice Head is Created (Add)
I would try that before writing custom code so upgrades will go smooth.
You first need to call GetNewInvcMisc, which you would use to create the Misc record, you would specify the InvoiceNum parameter and set the InvoiceLine to 0 since this would be a Header Misc charge for the entire Invoice.
Then you will need to immediately call another BO Method to set the MiscCode, OnChangeofMiscCode.
I would recommend you setup a new Misc Charge Code that is setup at 3% and then use the OnChangeofMiscCode to set the Misc Charge. You will need some data from the Method’s DataSet to provide the MiscCharge Sequence Number.
I wish I had some time to try this as I am trying to get to the point where I don’t have any custom code and this would be a great exercise.

This is to create misc. charge in Sales Order. Misc. charge in AR invoice is attached to the line and not at header level.

if (lCreateMinCharge == true)
{
bool recSelected;
string whereClause = “MiscCode = '” + “MIN” + “’”;
System.Data.DataSet dsMiscChrgAdapter = Epicor.Mfg.UI.FormFunctions.SearchFunctions.listLookup(this.oTrans, “MiscChrgAdapter”, out recSelected, false, whereClause);
if (recSelected)
{
System.Data.DataRow adapterRow = dsMiscChrgAdapter.Tables[0].Rows[0];
oTrans.GetNewOHOrderMsc();
edv = ((EpiDataView)this.oTrans.EpiDataViews[“OHOrderMsc”]);
edvRow = edv.CurrentDataRow;
edvRow.BeginEdit();
edvRow[“Company”] = edvOrderHed.dataView.Table.Rows[0][“Company”] ;
edvRow[“OrderNum”] = edvOrderHed.dataView.Table.Rows[0][“OrderNum”] ;
edvRow[“MiscCode”] = adapterRow[“MiscCode”];
edvRow[“MiscCodeDescription”] = adapterRow[“Description”];
edvRow[“FreqCode”] = adapterRow[“FreqCode”];
edvRow[“MiscAmt”] = adapterRow[“MiscAmt”];
edvRow[“DspMiscAmt”] = adapterRow[“MiscAmt”];
edvRow[“DocDspMiscAmt”] = adapterRow[“MiscAmt”];
edvRow[“DocMiscAmt”] = adapterRow[“MiscAmt”];
edvRow[“Rpt1DspMiscAmt”] = adapterRow[“MiscAmt”];
edvRow[“Rpt1MiscAmt”] = adapterRow[“MiscAmt”];
edvRow[“Description”] = adapterRow[“Description”];
edvRow[“Type”] = “A” ;
edvRow[“RowMod”] = “A” ;
edvRow.EndEdit();
oTrans.Update() ;
MessageBox.Show(“Minimum order charge $10 has been added. Please review.”, “Minimum Order Charge”, MessageBoxButtons.OK, MessageBoxIcon.Warning);
}
}