【问题标题】:Is it possible to modify the AutoFill string before showing in textfield?是否可以在文本字段中显示之前修改自动填充字符串?
【发布时间】:2019-07-05 03:15:02
【问题描述】:

我必须更改来自 AutoFill 的电话号码字符串,然后写入文本字段。我使用this method 来检测自动填充。但我无法访问该方法中的字符串。有可能吗?

【问题讨论】:

  • 这就是replacementString里面的内容。

标签: ios swift uitextfield autofill


【解决方案1】:
func textField(_ textField: UITextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) -> Bool

replacementString 是你的答案

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2010-12-03
    • 1970-01-01
    • 1970-01-01
    • 2020-04-21
    • 1970-01-01
    • 1970-01-01
    • 2010-10-03
    • 1970-01-01
    相关资源
    最近更新 更多