![]() |
Placing a formula in a cell of an unconstant row location
I'm trying to place a formula in a cell but I don't have a constant location of the row for the cell. See the code below as an exmple: ActiveCell.FormulaR1C1 = "=LEFT(R[YTDOrig]C[4],LEN(R[YTDOrig]C[4])-1)" How can I place a formula in a cell to achieve the results attempted by this code in an allowable syntax? Frank |
Placing a formula in a cell of an unconstant row location
Maybe...
ActiveCell.FormulaR1C1 = "=LEFT(R[" & YTDOrig & "]C[4],LEN(R[" _ & YTDOrig & "]C[4])-1)" wrote: I'm trying to place a formula in a cell but I don't have a constant location of the row for the cell. See the code below as an exmple: ActiveCell.FormulaR1C1 = "=LEFT(R[YTDOrig]C[4],LEN(R[YTDOrig]C[4])-1)" How can I place a formula in a cell to achieve the results attempted by this code in an allowable syntax? Frank -- Dave Peterson |
Placing a formula in a cell of an unconstant row location
On Jan 25, 8:01*pm, Dave Peterson wrote:
Maybe... ActiveCell.FormulaR1C1 = "=LEFT(R[" & YTDOrig & "]C[4],LEN(R[" _ * * * * * * * * * * * * * * * & YTDOrig & "]C[4])-1)" wrote: I'm trying to place a formula in a cell but I don't have a constant location of the row for the cell. See the code below as an exmple: ActiveCell.FormulaR1C1 = "=LEFT(R[YTDOrig]C[4],LEN(R[YTDOrig]C[4])-1)" How can I place a formula in a cell to achieve the results attempted by this code in an allowable syntax? Frank -- Dave Peterson IT WORKED!! Thanks for your help. Frank |
All times are GMT +1. The time now is 12:02 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com