Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7738215
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T08:12:26+00:00 2026-06-01T08:12:26+00:00

I am trying to detect dock key is pressed or not on my iPad.

  • 0

I am trying to detect dock key is pressed or not on my iPad. This dock key is a new feature in iOS 5. When this key is pressed the keyboard disappears. I need to detect it. When this key is pressed I need to change the frame of my view, but I couldn’t get any event by pressing this key.

I am trying to use the following function:

- (BOOL)textView:(UITextView *)textView shouldChangeTextInRange:(NSRange)range replacementText:(NSString *)text {
    NSLog(@"TEXT: %@", text);
    return YES;
}

When I pressed ‘A’ this function is called and print TEXT: A, but when dock key is pressed, this function wasn’t called!

Is there a way to detect dock key on iPad? For clarification, the dock key is available on iPad (only in iOS 5) at the bottom right corner of the keyboard.

ANSWER::::

I used the following code in viewDidLoad:

[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(keyboardWillHide) name:UIKeyboardWillHideNotification object:nil];

and I got the event in method -(void)keyboardWillHide

-(void)keyboardWillHide
{
    NSLog(@"Pressed...");
}

thanks borrrden.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T08:12:27+00:00Added an answer on June 1, 2026 at 8:12 am

    When the user presses the dock key, you will be notified via the UIKeyboardWillHideNotification from NSNotificationCenter.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to detect whether a user quickly presses a keyboard key twice, a
I'm trying to detect any touch on the iPhone's UIStatusBar but its not working.
I am trying to detect the collision from two objects. This collision has more
I'm trying to detect if a file exists at runtime, if not, create it.
I'm trying to detect an incoming call in the Lync client . This is
I'm trying to detect key combinations with jQuery, I've been researching for the last
I'm trying to detect the center of a circle. I try to do this
I am trying to detect an http response code of 302. This is my
Trying to detect if new elements are added or removed from the DOM in
I'm trying to detect change event for a select list as if from a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.