#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default Worksheet Function

Use this UDF:

Public Function ReturnNumerals(rng As Range) As String
Dim sStr As String, i As Long, sStr1 As String
Dim sChar As String
sStr = rng.Value
For i = 1 To Len(sStr)
sChar = Mid(sStr, i, 1)
If sChar Like "[0-9]" Then
sStr1 = sStr1 & sChar
End If
Next
ReturnNumerals = sStr1
End Function

--
Gary''s Student - gsnu200774


"Brennan" wrote:

Is there a worksheet function which will look into the contents of a cell,
find a value and return it?

Here is an example of what I am looking for:

Cell Return
Invoice No 1234 1234
Inv. No. 1235 1235
INum 1236 1236

As you can see, I am just looking for the invoice number even though they
may lable the "invoice no" differently.

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
Help with worksheet function Jonas Excel Worksheet Functions 0 November 29th 06 11:26 AM
IF worksheet function WOLLAM Excel Worksheet Functions 3 November 16th 06 06:40 PM
Reference the worksheet from a multiple worksheet range function ( DBickel Excel Worksheet Functions 1 May 28th 05 03:49 AM
IF Worksheet Function JB Excel Worksheet Functions 5 May 24th 05 11:21 PM
Can the offset worksheet function reference another worksheet AlistairJ Excel Worksheet Functions 2 May 9th 05 06:18 PM


All times are GMT +1. The time now is 01:22 PM.

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"