Ios &引用;PROVIDECREDERTIALWITHOUTHUSERINTERACTIONFORIDENTITY:“在没有用户交互的情况下;它不起作用了
我有一个在iOS 12上自动填充密码的应用程序。现在我想实现这个功能:Ios &引用;PROVIDECREDERTIALWITHOUTHUSERINTERACTIONFORIDENTITY:“在没有用户交互的情况下;它不起作用了,ios,objective-c,autofill,Ios,Objective C,Autofill,我有一个在iOS 12上自动填充密码的应用程序。现在我想实现这个功能: - (void)provideCredentialWithoutUserInteractionForIdentity:(ASPasswordCredentialIdentity *)credentialIdentity; 但我不能让它正常工作 自动填充已在“设置”中启用,也已在“我的应用”中启用 我已经阅读了文档,但这对我没有帮助 我已尝试从viewDidLoad,prepareCredentialistForServic
- (void)provideCredentialWithoutUserInteractionForIdentity:(ASPasswordCredentialIdentity *)credentialIdentity;
但我不能让它正常工作
自动填充已在“设置”中启用,也已在“我的应用”中启用
我已经阅读了文档,但这对我没有帮助
我已尝试从viewDidLoad
,prepareCredentialistForServiceIdentifiers
,…调用此函数,。。但这是愚蠢的,肯定行不通
- (void)provideCredentialWithoutUserInteractionForIdentity:(ASPasswordCredentialIdentity *)credentialIdentity {
ASPasswordCredential *credential = [[ASPasswordCredential alloc] initWithUser:@"theUsername" password:@"thePassword"];
[self.extensionContext completeRequestWithSelectedCredential:credential completionHandler:nil];
}
该函数应该在键盘上方显示凭据,但这不会发生。它只显示默认的“密码”按钮