Extract string between two characters not working.

RockandGrohl

Well-known Member
Joined
Aug 1, 2018
Messages
801
Office Version
  1. 365
Platform
  1. Windows
Hi all,

I'm trying to extract the string between two characters using this formula:

Excel Formula:
=MID(LEFT(K2,FIND("(",K2)-1),FIND(")",K2)+1,LEN(K2))

For instance, "DATA SHARER (1GB)" should return "1GB" and "DATA SHARER (5GB)" should return "5GB"

However, when I enter this formula, ensure it's looking at the correct cell, the formula completes and then shows a blank cell. No errors, and it's not showing me the value I need.

Has anyone encountered this before? Thank you.
 

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
How about
Excel Formula:
=SUBSTITUTE(REPLACE(K2,1,FIND("(",K2),""),")","")
 
Upvote 0
Solution
For some reason, looking between "(" and ")" doesn't work, but if I look between "(" and "GB" it seems to work just fine.
 
Upvote 0
Did you try the formula I suggested?
 
Upvote 0
Has anyone encountered this before?
Yes, I have done it. It is called "using the wrong formula". :)

If the parentheses are always at the end then you can use the formula that Fluff suggested or you could also try this which also deals with if the parentheses if they are not at the end.

23 01 09.xlsm
KL
2DATA SHARER (1GB)1GB
3DATA SHARER (5GB) ABC5GB
Extract
Cell Formulas
RangeFormula
L2:L3L2=MID(K2,FIND("(",K2)+1,FIND(")",K2)-FIND("(",K2)-1)
 
Upvote 0
Glad we could help & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,223,239
Messages
6,170,947
Members
452,368
Latest member
jayp2104

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top