WednesdayC
Board Regular
- Joined
- Nov 7, 2010
- Messages
- 201
- Office Version
-
- 2016
- Platform
-
- MacOS
Hi All
Please can anyone help me.
I am trying to add 2 variables (strmonth and stryear) to a formula using VBA.
strmonth contains "DEC" and stryear contains "16"
The plan is to become a title for an email.
I have tried various permutations. Example
This doesn't work and no does anything else I have tried. I assume I need an & somewhere, but can't see how.
Many thanks in advance.
Regards
Wednesday
Please can anyone help me.
I am trying to add 2 variables (strmonth and stryear) to a formula using VBA.
strmonth contains "DEC" and stryear contains "16"
The plan is to become a title for an email.
I have tried various permutations. Example
Code:
ActiveSheet.Cells(2, 6).FormulaR1C1 = "=RC[-3]" & strmonth & stryear
This doesn't work and no does anything else I have tried. I assume I need an & somewhere, but can't see how.
Many thanks in advance.
Regards
Wednesday