Share via


_OlkListBox.SetSelected Method

Sets the selected state of an item at the specified location in the list to the given Selected value.

Namespace:  Microsoft.Office.Interop.Outlook
Assembly:  Microsoft.Office.Interop.Outlook (in Microsoft.Office.Interop.Outlook.dll)

Syntax

'Declaration
<DispIdAttribute()> _
Sub SetSelected ( _
    Index As Integer, _
    Selected As Boolean _
)
'Usage
Dim instance As _OlkListBox
Dim Index As Integer
Dim Selected As Boolean

instance.SetSelected(Index, Selected)
[DispIdAttribute()]
void SetSelected(
    int Index,
    bool Selected
)

Parameters

  • Index
    Type: System.Int32

    A zero-based value that specifies the location of an item in the list.

  • Selected
    Type: System.Boolean

    True to indicate that the item should be selected, False to indicate that the item should not be selected.

Remarks

If Index is outside the range of the allowed values (between zero and ListCount-1), then an out-of-bounds error will be returned.

See Also

Reference

_OlkListBox Interface

_OlkListBox Members

Microsoft.Office.Interop.Outlook Namespace