A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » General Discussion
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Text Parsing with uneven lengths



 
 
Thread Tools Display Modes
  #1  
Old June 4th, 2010, 07:16 PM posted to microsoft.public.excel.misc
dks345
external usenet poster
 
Posts: 1
Default Text Parsing with uneven lengths

I have cells that contain data such as:

General Motors 22779
United States of America 1449
Carlsbad 712
Under 21 Children 12

I would like to parse the numbers at the end of each cell. Each number can
be different lengths and the text preceding the number can be different
lengths, too. Any ideas?
  #2  
Old June 4th, 2010, 07:55 PM posted to microsoft.public.excel.misc
T. Valko
external usenet poster
 
Posts: 15,759
Default Text Parsing with uneven lengths

Try this:

=--TRIM(RIGHT(SUBSTITUTE(A1," ",REPT(" ",100)),100))


--
Biff
Microsoft Excel MVP


"dks345" wrote in message
...
I have cells that contain data such as:

General Motors 22779
United States of America 1449
Carlsbad 712
Under 21 Children 12

I would like to parse the numbers at the end of each cell. Each number
can
be different lengths and the text preceding the number can be different
lengths, too. Any ideas?



  #3  
Old June 4th, 2010, 07:57 PM posted to microsoft.public.excel.misc
מיכאל (מיקי) אבידן
external usenet poster
 
Posts: 562
Default Text Parsing with uneven lengths

With the first string in cell A1 tyep the following formula into cell B1 and
copy down:
= - LOOKUP(1, -
MID(A1,MIN(FIND({0,1,2,3,4,5,6,7,8,9},A1&"01234567 89")),ROW($1:$256)))
Micky


"dks345" wrote:

I have cells that contain data such as:

General Motors 22779
United States of America 1449
Carlsbad 712
Under 21 Children 12

I would like to parse the numbers at the end of each cell. Each number can
be different lengths and the text preceding the number can be different
lengths, too. Any ideas?

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 03:10 AM.


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