Excel VBA Assignment by value or by reference?
问题 I have two objects of the same class which have a property that's an array of doubles (Double()), and I would like to do the following: Obj1.arr_property = Obj2.arr_property Is the above going to assign by value or by reference? If by reference, how to make it by value instead? 回答1: Everything that you assign with Set only copies the reference to the new variable, not the data. You do not use Set , so all values of the array are copied, not just the reference to the array. You actually cannot