Dela via


CDaoQueryDef::GetParamValue

Call this member function to retrieve the current value of the specified parameter stored in the querydef's Parameters collection.

virtual COleVariant GetParamValue( 
   LPCTSTR lpszName  
);
virtual COleVariant GetParamValue( 
   int nIndex  
);

Parameters

  • lpszName
    The name of the parameter whose value you want, for lookup by name.

  • nIndex
    The zero-based index of the parameter in the querydef's Parameters collection, for lookup by index. You can obtain this value with calls to GetParameterCount and GetParameterInfo.

Return Value

An object of class COleVariant that contains the parameter's value.

Remarks

You can access the parameter either by name or by its ordinal position in the collection.

For related information, see the topic "PARAMETERS Declaration (SQL)" in DAO Help.

Requirements

Header: afxdao.h

See Also

Reference

CDaoQueryDef Class

Hierarchy Chart

CDaoQueryDef::SetParamValue

Other Resources

CDaoQueryDef Members