UITextField.ShouldChangeTextInRange(UITextRange, String) Méthode

Définition

Permet au développeur d’application de rejeter par programme le texte de remplacement.

[Foundation.Export("shouldChangeTextInRange:replacementText:")]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 6, 0, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual bool ShouldChangeTextInRange (UIKit.UITextRange inRange, string replacementText);
abstract member ShouldChangeTextInRange : UIKit.UITextRange * string -> bool
override this.ShouldChangeTextInRange : UIKit.UITextRange * string -> bool

Paramètres

inRange
UITextRange

Plage de sélection actuelle dans laquelle le texte est modifié.

replacementText
String

Texte de remplacement à insérer.

Retours

true si l’ancien texte doit être remplacé par un nouveau texte ; false si l’opération de remplacement doit être abandonnée.

Attributs

S’applique à