SafeArrayGetLBound function
Gets the lower bound for any dimension of the specified safe array.
Syntax
HRESULT SafeArrayGetLBound( _In_ SAFEARRAY *psa, _In_ UINT nDim, _Out_ LONG *plLbound );
Parameters
- psa [in]
-
An array descriptor created by SafeArrayCreate.
- nDim [in]
-
The array dimension for which to get the lower bound.
- plLbound [out]
-
The lower bound.
Return value
This function can return one of these values.
| Return code | Description |
|---|---|
|
Success. |
|
One of the arguments is not valid. |
|
The specified index is out of bounds. |
Examples
HRESULT
CEnumPoint::Create(SAFEARRAY * psa, CEnumPoint ** ppenum)
{
long lBound;
HRESULT hresult;
CEnumPoint * penum;
// Verify that the SafeArray is the proper shape.
hresult = SafeArrayGetLBound(psa, 1, &lBound);
if(FAILED(hresult))
return hresult;
// Code omitted here for brevity.
}
Requirements
|
Header |
|
|---|---|
|
Library |
|
|
DLL |
|
Show: