<!--
{
  "availability" : [
    "macOS: 10.0.0 - 10.13.0"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSTableViewDataSource/tableView(_:namesOfPromisedFilesDroppedAtDestination:forDraggedRowsWith:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(pl)NSTableViewDataSource(im)tableView:namesOfPromisedFilesDroppedAtDestination:forDraggedRowsWithIndexes:"
  },
  "title" : "tableView(_:namesOfPromisedFilesDroppedAtDestination:forDraggedRowsWith:)"
}
-->

# tableView(_:namesOfPromisedFilesDroppedAtDestination:forDraggedRowsWith:)

Returns an array of filenames that represent the `indexSet` rows for a drag to `dropDestination`.

```
optional func tableView(_ tableView: NSTableView, namesOfPromisedFilesDroppedAtDestination dropDestination: URL, forDraggedRowsWith indexSet: IndexSet) -> [String]
```

## Parameters

`tableView`

The table view that sent the message.

`dropDestination`

The drop location where the files are created.

`indexSet`

The indexes of the items being dragged.

## Return Value

An array of filenames (not full paths) for the created files that the receiver promises to create.

## Discussion

This method is called when a destination has accepted a promise drag.

For more information on file promise dragging, see documentation on the NSDraggingSource protocol and [`namesOfPromisedFilesDropped(atDestination:)`](/documentation/AppKit/NSDraggingInfo/namesOfPromisedFilesDropped(atDestination:)).

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)