Remove any text values from numbers?

zendog1960

Active Member
Joined
Sep 27, 2003
Messages
451
I have a column of values that are like follows:

Column D
6'
36'
110'
etc

I have the same situation in column E as well. In column F I would like a formula that will add both values in Column D & E in each row. How do I get around the " ' " foot indicator with each value? Keep in mind that I have some 32 worksheets to go through.

THanks so much in advance!

Zen
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.

mikerickson

MrExcel MVP
Joined
Jan 15, 2007
Messages
23,993
In the long run, you may want the cells to have a custom format that appends the foot marker, so the cell contents are numbers and conversion is not needed. You could use Text to columns with a delimiter of ' to convert from text to numbers. The custom format would #' append the foot marker to the numbers.

For a short term solution.
=VALUE(LEFT((A1,LEN(A1)-1)) will change 12' (in A1) to 12
 

Yogi Anand

MrExcel MVP
Joined
Mar 12, 2002
Messages
11,454
I have a column of values that are like follows:

Column D
6'
36'
110'
etc

I have the same situation in column E as well. In column F I would like a formula that will add both values in Column D & E in each row. How do I get around the " ' " foot indicator with each value? Keep in mind that I have some 32 worksheets to go through.

THanks so much in advance!

Zen

Hi Zen:

I don't know the full scope of your problem ... but for what you have shown, use the following code ...
Code:
For Each cell In Range("F2:F4")
    cell.Value = Val(Cells(cell.Row, 4)) + Val(Cells(cell.Row, 5))
Next cell

and adapt it suit your needs.
 

Watch MrExcel Video

Forum statistics

Threads
1,130,444
Messages
5,642,188
Members
417,259
Latest member
gtacw

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
Top