Close window

Discussion in 'Mac Programming' started by onlyproductions, Mar 28, 2008.

  1. macrumors newbie

    Joined:
    Jan 6, 2008
    #1
    Hello i have a window which i want to close after a button is pressed how would i do this?
     
  2. Moderator emeritus

    kainjow

    Joined:
    Jun 15, 2000
  3. thread starter macrumors newbie

    Joined:
    Jan 6, 2008
    #3
    srry bout that im using coaco (objective c)
     
  4. macrumors 603

    whooleytoo

    Joined:
    Aug 2, 2002
    Location:
    Cork, Ireland.
    #4
    Use one of the following methods from the NSWindow class

    - orderOut to hide the window.
    - close to hide the window, and will also release the window object if it's set to release on close.
    - performClose to simulate a mouse-click on the close box, and will invoke the windowShouldClose method if it has been implemented.
     

Share This Page