ByRef v ByVal
"Jennifer Murphy" wrote:
It is my understanding that I should use the ByVal
keyword if I am planning to modify the parameter.
Is that correct?
It depends on your objectives.
Yes, use ByVal if you do not want the caller to see the change.
No, use ByRef (default) if you want the caller to see the change.
The latter is not unusual.
|