Calculation error

NikkiMc204

New Member
Joined
May 24, 2021
Messages
23
Office Version
  1. 365
  2. 2016
  3. 2013
Platform
  1. Windows
Hi can some kind soul help me with a calculation error I'm getting

I'm trying to extract the first numerical value from a text string. The text "10 FTE X 1hr = X days"

So i'm trying to extract the first number "10" I don't want any of the other numbers that show after the text FTE.

I've used this formula =(IFERROR(LEFT(H4,(FIND("FTE",H4,1)-1)),"")) which extracts the number 10 fine but when I go to add up all the figures using this formula i get a zero value =sum(h4:h500)

Where am i going wrong?
 

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.
Your formula is returning a string, you'll need to force it into an integer to allow for calculation using INT.

Excel Formula:
=(IFERROR(INT(LEFT(H4,(FIND("FTE",H4,1)-1))),""))
 
Upvote 0
Another option in-case you can have decimal numbers
Excel Formula:
=IFERROR(LEFT(H4,FIND("FTE",H4,1)-1)+0,"")
 
Upvote 0
Excel Formula:
=(IFERROR(VALUE(LEFT(H4,(FIND("FTE",H4,1)-1))),""))

Is, in fact, what i should have put. I'm so used to rigidly defined variables ?‍♂️ my bad! use Fluffs answer.
 
Upvote 0
Glad we could help & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,214,899
Messages
6,122,155
Members
449,068
Latest member
shiz11713

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