I’m new to Acumatica and trying to get my head around adding what seems like a simple customisation. I've been trying to get a warning to show when the line total is less than 50 on a Sales Order. I have looked at other examples of how to raise a warning and tried various things but I’m not entirely sure what event handler it should go in as it’s not a user updatable field. I also think I should be using a different method to show the error but not sure what.
The following is what I have:
protected void SOOrder_CuryLineTotal_FieldVerifying(PXCache cache, PXFieldVerifyingEventArgs e, PXFieldVerifying InvokeBaseHandler)
if(InvokeBaseHandler != null)
var row = (SOOrder)e.Row;
if (row == null) return;
if (row.CuryLineTotal < 50)
throw new PXSetPropertyException("The order total is below the Wholesale minimum of $50.", PXErrorLevel.Warning);
The error gets thrown as a message box on the screen before I even get to open the order that has a lower value for the Line Total. I just want it to show a warning exclamation mark next to the Line Total if it’s less than 50 once the Sales Order is displayed.
Sorry if this is a noob question.
Best answer by Naveen BogaView original