使用Excel中的VBA,我可以如何引用一个variables的单元格

正如标题所示,我无法弄清楚如何去一个单元格使用行的variables。 我已经附上我现在有的代码和评论部分是我有问题,谢谢!

Private Sub Go_Click() Dim id As Double Dim qt As Double Dim num As Double Dim rngSearch As Range, rngFound As Range id = Range("D4").Value qt = Range("E4").Value Set rngSearch = Range("A:A") Set rngFound = rngSearch.Find(What:=id, LookIn:=xlValues, LookAt:=xlPart) num = rngFound.Row If rngFound Is Nothing Then MsgBox "Stock ID Not Found" Else MsgBox rngFound.Row 'Range("O num.Value") = Range("O num.Value") - qt End If Range(rngFound.Row) = Range(rngFound.Row) - qt End Sub 

也许

 Range("O" & num).value=Range("O" & num).value-qt