LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 47
Default Function not working quite as required

A brilliant approach, Tom. Why didn't I think of that ...<g

Best wishes Harald
Excel MVP
Followup to newsgroup only please

"Tom Ogilvy" skrev i melding
...
This appears to work as well:

Function ValCat(r As Range)
Dim sVal As String
ValCat = 4
sVal = r.Text
If sVal Like "[A-Z]" Then ValCat = 1
If sVal Like "[A-Z]#" Then ValCat = 3
If sVal Like "[A-Z]##" Then ValCat = 3
If sVal Like "#" Then ValCat = 2
If sVal Like "##" Then ValCat = 2
End Function

--
Regards,
Tom Ogilvy



 
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
If function required Ravi Excel Discussion (Misc queries) 5 October 21st 08 01:09 PM
Function required Padraig Excel Discussion (Misc queries) 1 November 6th 07 05:40 PM
Help required with COUNTIF/AND function DAT Excel Worksheet Functions 3 August 3rd 06 07:38 PM
Function not working quite as required Harald Staff[_5_] Excel Programming 0 September 15th 03 01:52 PM
Function not working quite as required Bob Phillips[_5_] Excel Programming 1 September 15th 03 01:43 PM


All times are GMT +1. The time now is 01:04 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"