View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips[_6_] Bob Phillips[_6_] is offline
external usenet poster
 
Posts: 11,272
Default Counting Digits in a string

This will extract the digits at the end

=MID(A1,MIN(IF(ISERROR(1*(MID(A1,ROW(INDIRECT("A1: A"&LEN(A1))),1))),
255,ROW(INDIRECT("A1:A"&LEN(A1))))),99)

which is an array, so commit with Ctrl-Shift-Enter

--

HTH

RP
(remove nothere from the email address if mailing direct)


"bw" wrote in message
...
I want to know how many digits (numbers) there are at the end of a string,
so that I may move them elsewhere.
For example:
A1= "Consider This Example489".
This example has three digits.
Because I know A1 has 3 digits (after someone explains how to compute it),
then B1=Right(A1,3)=489.

Thanks,
Bernie