XLL+ Class Library

CXlFuncs::Match

Returns the relative position of an item in an array that matches a specified value in a specified order

[C++]
static int Match(
   unsigned short& uspos,
   const CXlOper& lookup_value,
   const CXlOper& lookup_array,
   unsigned short match_type = 1
);

Parameters

uspos

A reference to a value that will contain the requested data if the macro succeeds. It will contain zero if no value matches the lookup_value.

lookup_value

Value to be found in the first column of the table.

lookup_array

Table of information in which data is looked up.

match_type

Match type.

Return value

Zero if the function has been called successfully; non-zero if the function could not be called. See Error codes for a list of return values.

Remarks

See the Microsoft Excel on-line Help for full details about this function.

Requirements

Header: xlfuncs.h

See Also

CXlFuncs Class | CXlFuncs Methods