cas_valValidates CAS numbers. Syntaxlist cas_val(cas) string cas Descriptioncas_val() checks that a user entry has only two digits and two dashes and then applies a checksum technique. If the user entry is a valid CAS number, it is returned. If it is invalid, NULL is returned.
ExampleYou can use cas_val() in validation triggers for CAS fields in applications and to validate CAS values before submitting them to Thor or Merlin The following code shows a validation trigger for the CAS field:
{
if (parm[0])
field=cas_val(parm[0]); /* returns parm[0] if valid */
/* returns NULL if not valid */
}
Updated 19 May 1999. Copyright DataAspects Corp. 1998-1999 |