Share via


ContentControlListEntry.MoveUp Method

Word Developer Reference

Moves an item in a drop-down list or combo box content control up one item, so that it is before the item that originally preceded it.

Syntax

expression.MoveUp

expression   An expression that returns a ContentControlListEntry object.

Example

The following example moves the last item in the drop-down list or combo box content control up, so that it becomes the first item.

Visual Basic for Applications
  Dim objCC As ContentControl
Dim objCL As ContentControlListEntry
Dim intCount As Integer

Set objCC = ActiveDocument.ContentControls.Item(3)

If objCC.Type = wdContentControlComboBox Or _ objCC.Type = wdContentControlDropdownList Then

Set objCL = objCC.DropdownListEntries.Item(objCC.DropdownListEntries.Count)

For intCount = 1 To objCC.DropdownListEntries.Count
    objCL.<strong class="bterm">MoveUp</strong>
Next

End If

See Also