ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   String stuff again!! (https://www.excelbanter.com/excel-programming/314368-string-stuff-again.html)

Mannyluk

String stuff again!!
 
Hi,

Can someone tell me the function used to ectract a number from a string??

i.e. asdf12345asdfg

to give 12345

Cheers

Manny

JulieD

String stuff again!!
 
Hi

if all your strings start with four alpha followed by five numeric then use
=MID(A1,5,5)

Cheers
JulieD

"Mannyluk" wrote in message
...
Hi,

Can someone tell me the function used to ectract a number from a string??

i.e. asdf12345asdfg

to give 12345

Cheers

Manny




Frank Kabel

String stuff again!!
 
Hi
if the number is somethere in the middle of a string try:
=
IF(ISNUMBER(LOOKUP(2,1/MID(A1,seq,1),seq)),MID(A1,LOOKUP(2,1/MID(A1,102
4-seq,1),1024-seq),LOOKUP(2,1/MID(A1,seq,1),seq)-LOOKUP(2,1/MID(A1,1024
-seq,1),1024-seq)+1),"")


where seq is a defined name with the formula:
=ROW(INDIRECT("1:1024"))


--
Regards
Frank Kabel
Frankfurt, Germany


Mannyluk wrote:
Hi,

Can someone tell me the function used to ectract a number from a
string??

i.e. asdf12345asdfg

to give 12345

Cheers

Manny




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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com