I am trying to use Select Case to set the value of a variable called LimitPct. It is the percentage limit of an invoice quantity over the PO quantity we will accept. It is different for different vendors plus the may be ranges we negotiate for a given vendor. I prefer Basic Syntax b/c that is where my experience lies. My code is :
Rem Select Statement to determine Limit Vendor may exceed order
Rem Must be updated for each Vendor
Rem This method is preferrable to a table b/c of the complications of
Rem maintaining a table in MRP or on the server. IF there is a lot of
Rem vendors we'll evaluate using a table
Select Case {AP_Document.Vendor}
Case "STEIND"
Select Case {PO_Detail.Order_Quantity}
Case Is < 100
Formula = .10
Case Is < 1000
Formula = .03
Case Else
Formula = .02
End Select
Case Else
Formula = .03
End Select
I am trying to put this in the formula editor. I am getting the error message "The current formula cannot be used with the formula expert".
How do I accomplish this task? Am I correct in setting it up as a formula field? If not, where do I put the code?
Thank you very much for your help
Rem Select Statement to determine Limit Vendor may exceed order
Rem Must be updated for each Vendor
Rem This method is preferrable to a table b/c of the complications of
Rem maintaining a table in MRP or on the server. IF there is a lot of
Rem vendors we'll evaluate using a table
Select Case {AP_Document.Vendor}
Case "STEIND"
Select Case {PO_Detail.Order_Quantity}
Case Is < 100
Formula = .10
Case Is < 1000
Formula = .03
Case Else
Formula = .02
End Select
Case Else
Formula = .03
End Select
I am trying to put this in the formula editor. I am getting the error message "The current formula cannot be used with the formula expert".
How do I accomplish this task? Am I correct in setting it up as a formula field? If not, where do I put the code?
Thank you very much for your help