RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
Variants.VarCopyNoInd Function

Copies a System::Variant.

Pascal
procedure VarCopyNoInd(var Dest: Variant; const Source: Variant);
C++
VarCopyNoInd(Variant Dest, const Variant Source);

VarCopyNoInd copies the variant given by Source into the variant given by Dest. Calling VarCopyNoInd in C++ or Delphi code is equivalent to a simple variant assignment in Delphi code. 

Dest can be a System::Variant or an OleVariant, and it must be possible to assign a value to it.  

Source is defined as a System::Variant, but an OleVariant is also allowed because it is a compatible type. However, Source can't have a VarType that includes the varByRef bit. 

The following table lists the expected behavior when using System::Variant and OleVariant types as parameters:

Dest  
Source 
Behavior 
Works as expected.  
Works as expected.  
Works as expected.  
Source should be implicitly cast to an OleVariant.  

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!