functionchkEmail(email)
onerrorresumenext
dimi,l,pos1,pos2
chkEmail=true
ifisnull(email)thenchkEmail=false:exitfunction
pos1=instr(email,"@")
pos2=instrRev(email,".")
ifnot(pos1>0)ornot(pos2>0)orpos1>pos2then
chkEmail=false
endif
iferr.number<>0thenerr.clear
endfunction