Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Sets of Characters in Excel VBA


Thanks everyone, for your advice.
The "Like" operator is excellent and makes my code much more readabl
-

I'm sure you all know this - but just in case, the following works:

I wanted my test to return TRUE if the character was "0" to "9" or "."
While MyString Like "[0-9,.]"

sure beats
While MyString = "0" or MyString = "1" or MyString = "2" .......
etc

So once again, thanks for you help. You make life a lot easier

--
aussie_crai
-----------------------------------------------------------------------
aussie_craig's Profile: http://www.excelforum.com/member.php...fo&userid=1549
View this thread: http://www.excelforum.com/showthread.php?threadid=27071

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 863
Default Sets of Characters in Excel VBA

You are matching a comma as well. Was that intended?

On Wed, 20 Oct 2004 20:57:27 -0500, aussie_craig
wrote:


Thanks everyone, for your advice.
The "Like" operator is excellent and makes my code much more readable
-

I'm sure you all know this - but just in case, the following works:

I wanted my test to return TRUE if the character was "0" to "9" or "."
While MyString Like "[0-9,.]"

sure beats
While MyString = "0" or MyString = "1" or MyString = "2" ........
etc

So once again, thanks for you help. You make life a lot easier.


Reply
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
Excel graph 3 sets of data. 2 sets as lines 1 as column? AndyN Charts and Charting in Excel 2 July 11th 08 01:18 PM
In Excel find characters when multiple characters exist w/i a cel teacher-deburg Excel Worksheet Functions 1 December 5th 05 10:22 PM
anyway to go with excel two sets of data rob Charts and Charting in Excel 2 September 15th 05 04:51 AM
Sets of Characters in Excel VBA aussie_craig Excel Programming 5 October 20th 04 06:05 PM
Sets of Characters in Excel VBA aussie_craig[_2_] Excel Programming 0 October 20th 04 07:38 AM


All times are GMT +1. The time now is 02:32 PM.

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

About Us

"It's about Microsoft Excel"