I need to concatenate an address in the Range Object of Excel and I can not. The value is an integer variable. Here's the line of code:
Range("O10").Formula = "=SUM(O12:O" & "valor)"
I need to concatenate an address in the Range Object of Excel and I can not. The value is an integer variable. Here's the line of code:
Range("O10").Formula = "=SUM(O12:O" & "valor)"
Public Sub Teste()
Dim Valor As Integer
Valor = 3000
Range("A1").Formula = "=SUM(D1:D" & Valor & ")"
End Sub