Just create a loop in basic and convert each character to its ascii value
and then just check your range of allowed values.

   INPUT EMAIL.ADDRESS
   BAD.EMAIL = @FALSE
   FOR LETTER=1 TO LEN(EMAIL.ADDRESS)
       TEST=SEQ(EMAIL.ADDRESS[LETTER,1]) 
       IF TEST<32 OR TEST>126 THEN    ;*just check what every you need here
          BAD.EMAIL = @TRUE           ;*this is not what you want, but just
          EXIT                        ;*add your tweaks here
       END
   NEXT LETTER
   IF BAD.EMAIL THEN
      PRINT "YOUR EMAIL IS INVALID"
   END


ANTHONY

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Claus Derlien
Sent: Tuesday, May 03, 2005 4:09 AM
To: u2-users@listserver.u2ug.org
Subject: [U2] Validating an email adress 


Hi folks,

I'm completely new to the use of pattern matching in UniVerse, and i need a
neat way to validate an email adress, so i can return an error if it
contains any illegal chars, i guess legal chars is a-z,A-Z,0-9,.-_@

does anyone have nice way to do this ??

best regards from sunny denmark

Claus Derlien
edb-afdelingen
direkte : 63 13 86 69
email   : [EMAIL PROTECTED]

Frie Funktionfrer - faglig organisation og tvfrfaglig a-kasse - www.f-f.dk

****************************************************************************
***********************************************************
Denne email og alle filer vedlagt som bilag kan indeholde fortroligt
materiale, der kun er beregnet for adressaten, og maa ikke udleveres eller
kopieres til uvedkommende. Har De ved en fejltagelse modtaget denne email,
bedes De venligst omgaaende meddele os dette pr. telefon : 6313 8550. Paa
forhaand tak.
****************************************************************************
***********************************************************
This email and any files transmitted with it may contain confidential
information intended for the addressee(s) only. The information is not to be
surrendered or copied to unauthorised persons. If you have received this
communication in error, please notify us immediately by telephone: +45 6313
8550. Thank you.
****************************************************************************
***********************************************************
-------
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

-- 
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.11.1 - Release Date: 5/2/2005
 

-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.11.1 - Release Date: 5/2/2005
-------
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to