If I want to ensure that a CustomerID field is entered only once in SalesLogix, how is this best handled?

Question:

If I want to ensure that a CustomerID field is entered only once in SalesLogix, how is this best handled? I’ve tried the OnExitControl event but that doesn’t seem to work right.

Answer:

Have you tried the “OnValidate” event of the Form?

Not sure how much 7.5.2 has changed from 7.5.1, but if you look at the Account Detail form, it may already have a handler for the OnValidate event of the Form. It is on this Event where you could check the value of the field and prevent the user from going away from this record (or from Saving) by returning “False”

E.g.
Function AXFormValidate(Sender)
If Not MyCustomValidationFunction() Then
‘Issue Error Message (could be done inside the validation function)
‘Set Focus to Field (could be done inside the validation function)
AXFormValidate = False
End If
End Function

Submit a Comment

Your email address will not be published. Required fields are marked *

Subscribe To Our Newsletter

Join our mailing list to receive the latest Infor CRM (Saleslogix) and Creatio (bpm'online) news and product updates!

You have Successfully Subscribed!