Restricting copy,paste option for a particular UITextfield
Posted
by
EXC_BAD_ACCESS
on Stack Overflow
See other posts from Stack Overflow
or by EXC_BAD_ACCESS
Published on 2010-11-25T16:30:24Z
Indexed on
2011/01/09
6:53 UTC
Read the original article
Hit count: 205
Hi, My UIView contains Two UITextField.I need to restrict copy,paste option for one textfield.I don't want to restrict that for another.
When i am using the following code,Both the field gets restricted from copy,paste.
-(BOOL)canPerformAction:(SEL)action withSender:(id)sender
{
if ( [UIMenuController sharedMenuController] )
{
[UIMenuController sharedMenuController].menuVisible = NO;
}
return NO;
}
Can any one provide me the solution to solve my problem.
© Stack Overflow or respective owner