I have a lot of UITextViews in my screen and i want to add a new custom UIMenuItem for one of them.
It is possible to add a custom UIMenuItem just for a specific UITextView?
I use below code but i have my custom button for all UITextViews
UIMenuItem *menuItem = [[UIMenuItem alloc] initWithTitle:@"Read" action:@selector(readButtonAction)];
[[UIMenuController sharedMenuController] setMenuItems:[NSArray arrayWithObject:menuItem]];
Thanks
If you want
UIMenuItemto be displayed for a specificUITextViewyou can just add menuItem intextFieldDidBeginEditingmethod and add a specific tag to theUITextViewso that custom menu item displayed for that only :-