Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
ela ela is offline
external usenet poster
 
Posts: 16
Default function to extract numbers


13133..13558 (-)(426bp)
13714..13995 (-)(282bp)


match, exact, left, right, mid cannot help me extract the pairs of 13133,
13558; and 13714, 13995

is there any function rather than writing regular expression in VBscript (if
any) to achieve the purpose?


  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 896
Default function to extract numbers

=LEFT(A1,5)
to extract 13133

and

=MID(A1,FIND(" (-)",A1,1)-5,5)
to extract 13558

HIH

On 16 Kwi, 10:36, "ela" wrote:
* * * 13133..13558 (-)(426bp)
* * * 13714..13995 (-)(282bp)

match, exact, left, right, mid cannot help me extract the pairs of 13133,
13558; and 13714, 13995

is there any function rather than writing regular expression in VBscript (if
any) to achieve the purpose?


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,480
Default function to extract numbers

hi ela

Have you tried
=Left(A1,find(".",A1)-1) to get 13133
and
=MID(A1,FIND(".",A1)+2),5) to get 13358

or, if you wanted them as a pair, comma separated, then
=SUBSTITUTE(LEFT(A1,FIND(" ",A1)-1),"..",",")
--
Regards
Roger Govier

"ela" wrote in message
...

13133..13558 (-)(426bp)
13714..13995 (-)(282bp)


match, exact, left, right, mid cannot help me extract the pairs of 13133,
13558; and 13714, 13995

is there any function rather than writing regular expression in VBscript
(if any) to achieve the purpose?

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,651
Default function to extract numbers

On Thu, 16 Apr 2009 16:36:57 +0800, "ela" wrote:


13133..13558 (-)(426bp)
13714..13995 (-)(282bp)


match, exact, left, right, mid cannot help me extract the pairs of 13133,
13558; and 13714, 13995

is there any function rather than writing regular expression in VBscript (if
any) to achieve the purpose?


Data/Text-to-Columns can split that up
Delimited
Select <space
<other . (enter a dot)
Treat consecutive delimiters as one

--ron
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
how to extract numbers from imported cell with text and numbers? jyin Excel Discussion (Misc queries) 3 March 28th 07 01:14 PM
how to extract unique numbers once from a list of repeated numbers? [email protected] Excel Discussion (Misc queries) 2 May 2nd 06 04:17 PM
Extract numbers from cell with Text and Numbers wiredwrx New Users to Excel 3 April 18th 06 10:57 PM
Function to extract numbers from an alphanumeric cell diana Excel Worksheet Functions 4 March 13th 06 09:55 AM
Extract Fractional Numbers as Numbers NOT Date MrBill Excel Worksheet Functions 11 November 3rd 05 07:45 PM


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