Basic ? - How to return a single character to the left of the target

Ed_B

New Member
Joined
Mar 28, 2018
Messages
19
Office Version
  1. 2019
Platform
  1. Windows
My first post here with thanks in advance for any help.

I want to return only the number to the left of - which is separated by a space. This is the desired result:

[TABLE="width: 240"]
<tbody>[TR]
[TD]Luna Quartz Level 3 - Pool[/TD]
[TD="align: right"] 3[/TD]
[/TR]
[TR]
[TD]Supreme Matrix Level 1 - Spa[/TD]
[TD="align: right"]1[/TD]
[/TR]
</tbody>[/TABLE]

When I use the formula =LEFT(A2,(FIND("-",A2)-1)), all values to the left of - are returned instead of just the 3 and 1.

Thanks again.
 

Excel Facts

Lock one reference in a formula
Need 1 part of a formula to always point to the same range? use $ signs: $V$2:$Z$99 will always point to V2:Z99, even after copying
Hi,

Try this, it'll work for single or double digits:


Book1
AB
1Luna Quartz Level 3 - Pool3
2Supreme Matrix Level 1 - Spa1
Sheet13
Cell Formulas
RangeFormula
B1=TRIM(MID(A1,FIND(" -",A1)-2,2))+0
 
Upvote 0
You're welcome, welcome to the forum.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

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