title: MonoMac: and Xcode 4.0 error: "Unknown Window class MainWindow in Interface Builder file"
body: <p>I've created a new MonoMac project and opened the MainWindow.xib with Interface Builder (Xcode). After doing a simple change (renamed Window title), the project can't be built anymore.
  Does anyone know how to fix this?</p>
  
  <p>I'm using MonoDevelop 2.6, MonoFramework-2.10.1 with Xcode 4.0 on OS X 10.6.7.</p>
  
  <p>This is the error message:</p>
  
  <blockquote>
    <p>2011-03-28 18:45:39.986 HelloWorld[30332:613] Unknown Window class MainWindow in Interface Builder file,
         creating generic Window instead</p>
    
    <p>Unhandled Exception: System.InvalidCastException: Cannot cast from source type to destination type.
    at HelloWorld.MainWindowController.get_Window () &lt;0x0002e>
    at HelloWorld.AppDelegate.FinishedLaunching (MonoMac.Foundation.NSObject) &lt;0x0003d>
    at (wrapper dynamic-method) object.[HelloWorld.AppDelegate.Void FinishedLaunching(MonoMac.Foundation.NSObject)] (MonoMac.Foundation.NSObject,MonoMac.ObjCRuntime.Selector,MonoMac.Foundation.NSObject) &lt;0x00033>
    at (wrapper native-to-managed) object.[HelloWorld.AppDelegate.Void FinishedLaunching(MonoMac.Foundation.NSObject)] (MonoMac.Foundation.NSObject,MonoMac.ObjCRuntime.Selector,MonoMac.Foundation.NSObject) &lt;0x000eb>
    at (wrapper managed-to-native) MonoMac.AppKit.NSApplication.NSApplicationMain (int,string[]) &lt;0x00003>
    at MonoMac.AppKit.NSApplication.Main (string[]) &lt;0x00017>
    at HelloWorld.MainClass.Main (string[]) &lt;0x00019></p>
  </blockquote>
  
  <p>Thanks for any help.</p>
  
  <p>Cheers</p>
  
  <p>PS: I found a troubleshooting help on <a href="http://monotouch.net/Documentation/Troubleshoot#Unknown_class_XXXX_in_Interface_Builder_filebut">http://monotouch.net/Documentation/Troubleshoot#Unknown_class_XXXX_in_Interface_Builder_filebut</a> I guess it doesn't count in this case, since the class MainWindow already exists by default..</p>