NSUnknownKeyException error

Discussion in 'iOS Programming' started by Blakely028, Jul 5, 2010.

  1. Blakely028
    Expand Collapse
    macrumors regular

    Blakely028

    Joined:
    Apr 29, 2008
    Location:
    Scotland
    #1
    Hi there,

    I made an application that has a slider, textbox and a button and I got a NSUnknownKeyException error. The app loads and then closes almost instantaneously. Here is some of the error:

    Code:
    [Session started at 2010-07-05 23:04:47 +0100.]
    2010-07-05 23:04:49.078 Slider[1119:207] Unknown class SliderAppDelegate in Interface Builder file.
    2010-07-05 23:04:49.082 Slider[1119:207] *** Terminating app due to uncaught exception 'NSUnknownKeyException', reason: '[<UICustomObject 0x5c077b0> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key window.'
    *** Call stack at first throw:
    (
    Any help would be appreciated! :)
     
  2. robbieduncan
    Expand Collapse
    Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #2
    Did you create a class SliderAppDelegate then delete it or something. The error is quite clear: it's trying to create an instance of SliderAppDelegate but the class does not exist.
     
  3. Blakely028
    Expand Collapse
    thread starter macrumors regular

    Blakely028

    Joined:
    Apr 29, 2008
    Location:
    Scotland
    #3
    Hi, yeah I did delete it. Should I reinstate it?
     
  4. robbieduncan
    Expand Collapse
    Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #4
    Depends if you want/need it or not. If not then update the definitions in IB to remove all references to that class (even if you don't have any instances of it make sure the class is not in the Classes tab in the Library.
     

Share This Page