function islength(val) if len(val.value)> 0 then islength = true else msgbox "This value can't be empty" val.select islength = false end if end function function isemail(val) if islength(val) then e=val.value if instr(e,"@")>0 and instr(e,".")>0 and len(e)>5 then isemail=true else msgbox "please enter a proper email address." val.select isemail=false end if end if end function function isnumber(val) if isnumeric(val.value) then isNumber=true else msgbox "This value must be numeric" val.select isnumber=false end if end function