I found how to resolve the error by adding the full library path system.Text.RegularExpressions.Regex.IsMatch like:
system.Text.RegularExpressions.Regex.IsMatch(DateTaskAttrib, “(JAN|FEB|MAR|APR|MAY|JUN|JUL|AUG|SEP|OCT|NOV|DEC)-\d{2}”)
Hope helps someone else