1
I need to take the contents of cells identified in a variable. It is possible?
Code:
VTI40 = "J44"
VTF40 = "J47"
VTI39 = "H44"
VTF39 = "H47"
QtdVal = Range("B60").Value
QtdInv = 40 - QtdVal
For i = 40 To QtdInv Step -1
VTI = "VTI" & i
VTF = "VTF" & i
CelI = Range(VTI).Value -> Aqui o conteúdo da célula "J44"
CelF = Range(VTF).Value -> Aqui o conteúdo da célula "J47"
Next i
I suggest using
.Cells()
in this loop and not Range. But do a [mcve] with the table data as it is difficult to visualize this way. Create in example with fictitious data.– danieltakeshi
Your question seems to have some problems and your experience here in Stack Overflow may not be the best because of it. We want you to do well here and get what you want, but for that we need you to do your part. Here are some guidelines that will help you: Stack Overflow Survival Guide in English (short version). If the solution is very simple it is still possible for someone to do so in the comments.
– danieltakeshi