XLL+ Class Library (6.3)

CXlControlListBox::GetText

Retrieves the application-supplied doubleword value associated with the specified list-box item

int GetText(
   int nIndex,
   const char* pszBuffer
) const;
void GetText(
   int nIndex,
   CString& rString
) const;

Parameters

nIndex

Specifies the zero-based index of the item in the list box.

pszBuffer

Points to the buffer that receives the string. The buffer must have sufficient space for the string and a terminating null character. The size of the string can be determined ahead of time by calling the GetTextLen member function.

nIndex

Specifies the zero-based index of the item in the list box.

rString

A reference to a CString object

Return Value

The length (in bytes) of the string, excluding the terminating null character. If nIndex does not specify a valid index, the return value is -1.

Remarks

Gets a string from a list box. The second form of this member function fills a CString object with the string text.

Requirements

Header: xldialog.h

See Also

CXlControlListBox Class | CXlControlListBox Methods