How do I close the keyboard

Discussion in 'iOS Programming' started by iphonedevelop18, Mar 16, 2009.

  1. iphonedevelop18 macrumors member

    Joined:
    Feb 26, 2009
    #1
    Say I have a text field and I open the keyboard up by clicking on it, how then do I close the keyboard as there are buttons underneath that need to be pushed.
     
  2. dejo Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #2
    Please read the iPhone Application Programming Guide first.
     
  3. yayaba macrumors 6502

    Joined:
    Apr 24, 2007
    Location:
    San Francisco Bay Area
    #3
    You need to assign the UITextField's delegate to whatever is the parent of the UITextField. Then use the delegate function that corresponds to whether or not to use the Return key and in that function return YES and resign the first responder.

    I'm not 100% sure of the concept of first responders though, I just know it needs to be done...
     

Share This Page