LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Frank Cutre
 
Posts: n/a
Default test for "special characters" in text

Hi,

I need to make sure that a cell contains NO SPECIAL CHARACTERS (including
the <SpaceBar) during data entry.

I've tried:
=len(cellReference)=len(substitute(cellReference,o r(char(32),char(34),...etc
),"")

but Excel doesn't like the OR funtion (2nd parameter) inside SUBSTITUTE.

How do you test if a cell reference contains ANY of the "special text
characters" (from list below)?

space
double quote
number
dollar
percent
ampersand
apostrophe
open parenthesis
close parenthesis
asterisk
plus
comma
hyphen
period
forward slash
colon
semi-colon
less than
equal
greater than
at symbol
open square bracket
backslash
close square bracket
caret
underscore
single quote (under tilde)
open curly bracket
pipe (above backslash)
close curly bracket
tilde


Thanx for your time... (^_^)



 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Linked cells and text boxes Alexlondon11 Excel Discussion (Misc queries) 2 November 23rd 05 04:10 PM
dates and text Sloth Excel Discussion (Misc queries) 0 November 18th 05 04:16 PM
Find all text instances in a sheet and add one number from each row Greg Excel Discussion (Misc queries) 1 January 31st 05 11:45 PM
How do I test a cell for part of text East London Excel Worksheet Functions 1 January 26th 05 11:36 AM
change text color based on logical test T3nMan Excel Worksheet Functions 1 January 19th 05 04:30 PM


All times are GMT +1. The time now is 12:07 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"