---
title: "textFieldDidBeginEditing(_:)"
framework: uikit
role: symbol
role_heading: Instance Method
path: "uikit/uitextfielddelegate/textfielddidbeginediting(_:)"
---

# textFieldDidBeginEditing(_:)

Tells the delegate when editing begins in the specified text field.

## Declaration

```swift
optional func textFieldDidBeginEditing(_ textField: UITextField)
```

## Parameters

- `textField`: The text field in which an editing session began.

## Discussion

Discussion This method notifies the delegate that the specified text field just became the first responder. Use this method to update state information or perform other tasks. For example, you might use this method to show overlay views that are visible only while editing. Implementation of this method by the delegate is optional.

## See Also

### Managing editing

- [textFieldShouldBeginEditing(_:)](uikit/uitextfielddelegate/textfieldshouldbeginediting(_:).md)
- [textFieldShouldEndEditing(_:)](uikit/uitextfielddelegate/textfieldshouldendediting(_:).md)
- [textFieldDidEndEditing(_:reason:)](uikit/uitextfielddelegate/textfielddidendediting(_:reason:).md)
- [textFieldDidEndEditing(_:)](uikit/uitextfielddelegate/textfielddidendediting(_:).md)
- [UITextField.DidEndEditingReason](uikit/uitextfield/didendeditingreason.md)
