Common Validation Class for: Item.ItemNum
This class is designed to validate item numbers.
If class is called using default constructor FldItemnum(mbv)
- The validation checks only that the entered value
exists in the item table for the current item set identifier.
- The error message (invaliditem) will alert caller
that the itemnum was not found in Item table.
If class is called using constructor with criteria FldItemnum(mbv, criteriaString)
- The validation will check both that the entered value
exists in the item table, and that it has the criteria passed into constructor
- The error message will alert caller that itemnum
with criteria X (ex: rotating) was not valid.
- The list which will be associated with any derived field will use the criteria
to populate itself - ex: rotating will only produce rotating items in a list.
Because the attribute name of the "itemnum" field can vary from object to object, the
code will account for that issue and gather the name of the attribute dynamically.
The name for the item set identifier must always be "itemsetid".