<-- Previous || Up || Next -->

Set Variants Sub
Convert Values Class

Public Sub SetVariants( _
      ByRef rDest As Variant _
    , ByRef rSrc As Variant _
    )

Sets one argument to the value of another.
Assumes that the arguments are of compatible types.

For example, the following types of arguments would be compatible:
    Integer and Variant with Integer value.
    String and Variant with String value.
    Double and Variant with Long value.
    Variant with Integer value and Variant with String value.
Example:
    Assuming
       Dim varOne As Variant
       Dim varTwo As Variant
       varOne = "1"
       varTwo = "2"
    for example
       SetVariants varOne, varTwo
    leaves
       varOne = "2"
       varTwo = "2"
See also:
    SwapVariants Function
rDest: Value which is to be set to that of rSrc.
rSrc: Value which is to be copied into rDest.
Note: This function only modifies the rDest argument. rSrc is passed by-reference for performance reasons.
v1.3 Addition: This new Subroutine is used by the Stack data structure Class.

Copyright 1996-1999 Entisoft
Entisoft Tools is a trademark of Entisoft.