contents   index   previous   next



SafeArrayCopyData

 

f90VB Modules

 

f90VBDefs, f90VBSafeArrays

Summary

 

Copies the source array to the target array after releasing any resources in the target array. This subroutine is similar to SafeArrayCopy, except that the target array has to be set up by the caller before the subroutine is called. The target is not allocated or reallocated.

Syntax

 

subroutine SafeArrayCopyData (SARefSrc, SARefDest, iRet)

{
integer(SAFEARRAY_KIND),intent(in):: SARefSrc |
type(FSafeArray),intent(in):: SARefSrc |
}
{
integer(SAFEARRAY_KIND),intent(inout):: SARefDest |
type(FSafeArray),intent(inout):: SARefDest |
}
integer(HRESULT_KIND),intent(out),optional:: iRet

Arguments

 

SARefSrc [Input]

A handle to, or a Fortran Safe Array structure containing a handle to, the Safe Array to be copied.

 

SARefDest [Output]

A handle to, or a Fortran Safe Array structure containing a handle to, an existing Safe Array that will contain the copy of SARefSrc.

 

 

iRet [Output/Optional]

Upon return, iRet contains S_OK or an error code. See comments for more information.

Comments

 

This subroutine is identical to SafeArrayCopy except that any resources in the destination Safe Array are released before the copy operation is performed.

Argument iRet

 

Indicates success or failure of the subroutine. The following codes can be returned in this argument:

 

 

Value returned in argument iRet Description
S_OK Success.
E_INVALIDARG One of the arguments is invalid.
E_OUTOFMEMORY Memory for the new Safe Array could not be allocated.

Examples

 

See example for subroutine SafeArrayCopy.

Related Topics

 

For information about: See:
Copying a Safe Array SafeArrayCopy
Creating a Safe Array SafeArrayCreate

 


SafeArrayCreate