<!--
{
  "availability" : [
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSTextField/textDidBeginEditing(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSTextField(im)textDidBeginEditing:"
  },
  "title" : "textDidBeginEditing(_:)"
}
-->

# textDidBeginEditing(_:)

Posts a notification to the default notification center that the text is about to go into edit mode.

```
func textDidBeginEditing(_ notification: Notification)
```

## Parameters

`notification`

The [`textDidBeginEditingNotification`](/documentation/AppKit/NSControl/textDidBeginEditingNotification) notification to post to the default notification center.

## Discussion

This action causes the text field’s delegate to receive a <doc://com.apple.documentation/documentation/ObjectiveC/NSObject-swift.class/controlTextDidBeginEditing:> message. See [`NSControl`](/documentation/AppKit/NSControl) for more information about the text delegate method.

---

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)