---
title: "tokenFieldCell(_:editingStringForRepresentedObject:)"
framework: appkit
role: symbol
role_heading: Instance Method
path: "appkit/nstokenfieldcelldelegate/tokenfieldcell(_:editingstringforrepresentedobject:)"
---

# tokenFieldCell(_:editingStringForRepresentedObject:)

Allows the delegate to provide a string to be edited as a proxy for the represented object.

## Declaration

```swift
@MainActor optional func tokenFieldCell(_ tokenFieldCell: NSTokenFieldCell, editingStringForRepresentedObject representedObject: Any) -> String?
```

## Parameters

- `tokenFieldCell`: The token field cell that sent the message.
- `representedObject`: A represented object of the token field.

## Return Value

Return Value A string that’s an editable proxy of the represented object, or nil if the token should not be editable.

## See Also

### Editing a Tokenized Strings

- [tokenFieldCell(_:completionsForSubstring:indexOfToken:indexOfSelectedItem:)](appkit/nstokenfieldcelldelegate/tokenfieldcell(_:completionsforsubstring:indexoftoken:indexofselecteditem:).md)
- [tokenFieldCell(_:representedObjectForEditing:)](appkit/nstokenfieldcelldelegate/tokenfieldcell(_:representedobjectforediting:).md)
- [tokenFieldCell(_:shouldAdd:at:)](appkit/nstokenfieldcelldelegate/tokenfieldcell(_:shouldadd:at:).md)
