Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Add Comma to this RegEx

Posted on 2006-11-14
6
Medium Priority
?
990 Views
Last Modified: 2008-02-01
How do I add commas as an acceptable character to this RegEx definition set?

Dim regEx
Set regEx = New RegExp
regEx.Global = true
regEx.Pattern = "[^0-9a-z A-Z@._-]"

Thanks!
0
Comment
Question by:bsowards
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 18

Expert Comment

by:Morcalavin
ID: 17939714
Have you tried this?
regEx.Pattern = "[^0-9a-z A-Z@._-,]"
0
 

Author Comment

by:bsowards
ID: 17939719
Yes, it failed
0
 
LVL 18

Expert Comment

by:Morcalavin
ID: 17939729
Try this:
regEx.Pattern = "[^0-9a-z A-Z@._-\,]"
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:bsowards
ID: 17939742
Microsoft VBScript runtime  error '800a139d'

Invalid range in character set

/forms/contact_submit.asp, line 20
0
 
LVL 18

Accepted Solution

by:
Morcalavin earned 1000 total points
ID: 17939778
Oh i see.  - is a special character.  escape it.
regEx.Pattern = "[^0-9a-z A-Z@._\-,]"
0
 

Author Comment

by:bsowards
ID: 17939791
Thank You!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
I have helped a lot of people on EE with their coding sources and have enjoyed near about every minute of it. Sometimes it can get a little tedious but it is always a challenge and the one thing that I always say is:   The Exchange of informatio…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question