Thank you. It's working...
I'm at my wits end with this one...
I'm passing a value entered from a textbox on my Excel sheet (see code below) ....Code
So I'm passing the value to from "DaysToCompletion" this sub routine below and I'm trying to use the value stored in the variable in the formula below to be placed in cell "D19". However, I'm getting an error when the program hits the formula where I'm trying to subtract cell A19 from cell B19 and add the value of the variable "DaysToCompletion"..
Any help will be greatly appreciatedCode
Sub v_GetDaysToCompletion(ByVal DaysToCompletion As Integer) wksTarget.Range("D19").Value = "=(B19-A19) + DaysToCompletion" With wksTarget.Range("A18").CurrentRegion Set rngTarget = .Offset(1).Resize(.Rows.Count - 1) End With rngTarget.Columns(4).FillDown wksTarget.Range("A18:D18").Font.Bold = True Application.CutCopyMode = False End Sub