Approval as per Value

I have a field called ‘AdjTotal’ which is the sum of a number of fields.I have a number of approvers that need to be notified and approve the document then pass onto next approver. When the L1 Approval Button is selected it needs to send a link to either L2, L3 or L4 for approval depending on the total of the ‘AdjTotal’.

The code below works for the ‘greater $1000 and greater $5000’. I need to add the’ less than $1000’ but nothing I tried works.


L1 Approval Button

tmpYesNo := @Prompt([YesNo]; “Approve Adjustment”; “Do you want to approve this adjustment?”);

@If( tmpYesNo = 1 ; @Success ;

@Do(FIELD L1Status := “Not Approved” ;

FIELD L1ApprovalDate := “”;

FIELD L1ApprovedBy := “Rejected By” + @Name([CN] ; @UserName) ;

@Return( “” )));

FIELD L1Status:= “Approved”;

FIELD L1ApprovalDate := @Today;

FIELD L1ApprovedBy := @Name([CN] ; @UserName);

SendTo2:= L2SupplyChainMgr : L2Backup;

SendTo3:= L3SupplyChainVP : L3Backup;

SendTo4:= L4GroupFinancialOfficer : L4Backup;

SendTo5:= L5ChiefFinancialOfficer : L5Backup;

SendTo := @If(AdjTotal>=5000;SendTo3;SendTo2 );

@MailSend(SendTo;“”;“”;(“NOTIFICATION: GDT Warehouse Stock Adjustment Request”) : “”;“”;"NOTIFICATION: Please review and Authorise Stock Adjustment ";[IncludeDoclink])


I have FIVE Approval Levels.

L1 Approval (button)

L1 needs to SendTo L2 if greater than $1000

L1 needs to SendTo L3 if greater than $5000

L1 needs to SendTo L4 if less than $1000

L2 Approval (button)

L2 needs to SendTo L4

L3 Approval (button)

L3 needs to SendTo L4

L4 Approval (button)

L4 SendTo L5 if greater than $50,000

L4 SendTo or back to RequestorName (field name)

L5 Approval (button)

L5 SendTo RequestorName (field name)

Your help would be very appreciated.

Subject: I don’t see where you’re doing a check for 1000 but anyway

SendTo := @If(AdjTotal<1000; SendTo4;AdjTotal<5000;SendTo2;SendTo3 );

FYI, your problem is solution is almost exactly the same as one of the examples in Domino Designer, be sure to look at the examples they are great.

  1. In this example, @If looks at the value in the CostOfGoods field; if the value is greater than 12.45, then the string “Over Budget” is returned; if not, Notes skips to the next condition. The second condition also evaluates the CostOfGoods field and if the value is less than 12.45, then the condition is True and Notes returns the string “Bill of Materials OK.” If the value is neither greater than nor less than 12.45, Notes moves on to the “else” action specified, and the string “Estimate Right on Target” is returned.

@If(CostOfGoods>12.45;“Over Budget”;CostOfGoods<12.45;

“Bill of Materials OK”;“Estimate Right on Target”)

Subject: Thank you.