Re: small simple regexp favor
- From: aaron.kempf@xxxxxxxxx
- Date: 29 Jun 2006 08:20:13 -0700
hey while you're there can you help me force all lower case into upper
case?
I swear; can I mail you a $20 bill or something?
-Aaron
ekkehard.horner wrote:
aaron.kempf@xxxxxxxxx wrote:
Can you guys PLZ PLZ PLZ write me a regexp string to filter outTry this
anything other than A-Z 1-0 and also allow these 5 special characters??
/
:
\
.
And {space}
Again; allow anything from A-Z and from 1-0 and also allow these 5
special characters:
Backslash, forwardslash, period, space, colon
Thanks
-Aaron
Dim aTests : aTests = Array( "AZ01\/. :" , "AZ01\/. :" _
, "az01\/. :" , "01\/. :" _
, "AZ23\/. :" , "AZ\/. :" _
, "BC10\/. :{=´", "BC10\/. :" _
)
Dim oRE : Set oRE = New RegExp
' allow=keep anything from A-Z and from 1-0 and also allow these 5
' special characters: Backslash, forwardslash, period, space, colon
oRE.Pattern = "[^A-Z0-1\\/. :]"
oRE.Global = True
Dim nIdx, sMsg, sRes
For nIdx = 0 To UBound( aTests ) Step 2
sMsg = nIdx & " |" + aTests( nIdx ) + "| => |"
sRes = oRE.Replace( aTests( nIdx ), "" )
sMsg = sMsg + sRes + "| => " + CStr( sRes = aTests( nIdx + 1 ) )
WScript.Echo sMsg
Next
.
- Follow-Ups:
- Re: small simple regexp favor
- From: aaron . kempf
- Re: small simple regexp favor
- References:
- small simple regexp favor
- From: aaron . kempf
- Re: small simple regexp favor
- From: ekkehard.horner
- small simple regexp favor
- Prev by Date: Re: small simple regexp favor
- Next by Date: Re: VB Script problem with access database
- Previous by thread: Re: small simple regexp favor
- Next by thread: Re: small simple regexp favor
- Index(es):
Relevant Pages
|
Loading