Is there a way to reference a cell in a worksheet in a workbook without
having to do the following each time I need access to the cells data?
Would like to assign it to something like RefCell so that I could extract, modify then replace the cells contents.
ex:
having to do the following each time I need access to the cells data?
Code:
If Workbook(sReference).Worksheets(sAMS).Range("A" & sAMSRPTR, sAMSLastCol & aAMSRPTR) = "hello" then
Workbook(sReference).Worksheets(sAMS).Range("A" & sAMSRPTR, sAMSLastCol & aAMSRPTR) = "Hi"
Else
Workbook(sReference).Worksheets(sAMS).Range("A" & sAMSRPTR, sAMSLastCol & aAMSRPTR) = "Goodby"
End If
Would like to assign it to something like RefCell so that I could extract, modify then replace the cells contents.
ex:
Code:
If RefCell = "Hello" then
RefCell = "Hi"
Else
RefCell = "Goodby"
End If