Vba - combine formulas stored as variables

moni_tm

New Member
Joined
Nov 4, 2015
Messages
29
Hello,

Please can anyone help. And please forgive any errors in terminology.

I have stored two formulas as variables which I can see are correct on the Locals window. I now want to combine these two formulas together in another cell.
So far I have following but I cant seem to work out how to combine them..

Code:
F1 = Range("E1:E1000").Find("FTE's").Offset(1, 1).Formula
F2 = Range("E1:E1000").Find("FTE's").Offset(1, 2).Formula

Range("E1:E1000").Find("FTE's").Offset(0, 1).Formula = "=" & F1 + F2

Can anyone help?!

All help, as always is much appreciated.

Tom
 

Excel Facts

Create a chart in one keystroke
Select the data and press Alt+F1 to insert a default chart. You can change the default chart to any chart type
Hello,

Please can anyone help. And please forgive any errors in terminology.

I have stored two formulas as variables which I can see are correct on the Locals window. I now want to combine these two formulas together in another cell.
So far I have following but I cant seem to work out how to combine them..

Code:
F1 = Range("E1:E1000").Find("FTE's").Offset(1, 1).Formula
F2 = Range("E1:E1000").Find("FTE's").Offset(1, 2).Formula

[B][COLOR="#FF0000"]Range("E1:E1000").Find("FTE's").Offset(0, 1).Formula = "=" & F1 + F2[/COLOR][/B]

Can anyone help?!
Untested (as I am about to go to sleep), but see if this works...

Range("E1:E1000").Find("FTE's").Offset(0, 1).Formula = F1 & "+" & Mid(F2, 2)

Both formulas start with an equal sign, so I used the equal sign from F1 to start the combined formula but removed the equal sign from the second formula.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,225,738
Messages
6,186,734
Members
453,369
Latest member
juliewar

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