---
title: "tableView(_:updateDraggingItemsForDrag:)"
framework: appkit
role: symbol
role_heading: Instance Method
path: "appkit/nstableviewdatasource/tableview(_:updatedraggingitemsfordrag:)"
---

# tableView(_:updateDraggingItemsForDrag:)

Implement this method to allow the table to update dragging items as they are dragged over a view.

## Declaration

```swift
@MainActor optional func tableView(_ tableView: NSTableView, updateDraggingItemsForDrag draggingInfo: any NSDraggingInfo)
```

## Parameters

- `tableView`: The table view.
- `draggingInfo`: The dragging information.

## Discussion

Discussion Required for multi-image dragging. Typically this will involve invoking enumerateDraggingItems(options:for:classes:searchOptions:using:) on the draggingInfo parameter value and setting the draggingItem object’s imageComponentsProvider to a proper image based on the content. For view-based table views, you can use the NSTableCellView method draggingImageComponents. For cell-based tables, use the NSCell method draggingImageComponents(withFrame:in:).

## See Also

### Drag and Drop

- [Supporting Table View Drag and Drop Through File Promises](appkit/supporting-table-view-drag-and-drop-through-file-promises.md)
- [tableView(_:acceptDrop:row:dropOperation:)](appkit/nstableviewdatasource/tableview(_:acceptdrop:row:dropoperation:).md)
- [tableView(_:namesOfPromisedFilesDroppedAtDestination:forDraggedRowsWith:)](appkit/nstableviewdatasource/tableview(_:namesofpromisedfilesdroppedatdestination:fordraggedrowswith:).md)
- [tableView(_:validateDrop:proposedRow:proposedDropOperation:)](appkit/nstableviewdatasource/tableview(_:validatedrop:proposedrow:proposeddropoperation:).md)
- [tableView(_:writeRowsWith:to:)](appkit/nstableviewdatasource/tableview(_:writerowswith:to:).md)
- [tableView(_:draggingSession:willBeginAt:forRowIndexes:)](appkit/nstableviewdatasource/tableview(_:draggingsession:willbeginat:forrowindexes:).md)
- [tableView(_:draggingSession:endedAt:operation:)](appkit/nstableviewdatasource/tableview(_:draggingsession:endedat:operation:).md)
