• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Extracting Number Inside parenthesis

In the above solutions using Mid() and Left() the answer is being returned as a Text string. You will see that the result is left aligned, where as numbers are right aligned

Technically to convert it to a number you can either use a Value() function of perform some maths on it

eg:
=MID(B3,FIND("(",B3)+1,LEN(B3)-FIND("(",B3)-1)
Should be
=Value(MID(B3,FIND("(",B3)+1,LEN(B3)-FIND("(",B3)-1))
or
=- -MID(B3,FIND("(",B3)+1,LEN(B3)-FIND("(",B3)-1)

=Left(B3,FIND("(",B3)-1)
Should be
=Value(Left(B3,FIND("(",B3)-1))
or
=- - Left(B3,FIND("(",B3)-1)
 
@Somendra,

Yes and No

In Excel, doing what you said works.

But I have seen examples used in say Open Office etc where the cells value is not picked up because it is text
 
Back
Top