[Mono-osx] MonoMac unrecognized selector
claunia at claunia.com
Mon Nov 8 12:32:49 EST 2010
Ok got it.
El 08/11/2010, a las 17:23, Natalia Portillo escribió:
> There is no need to.
> The fail was because NSPrincipalClass in Info.plist was set to AppDelegate.
> Deleting it and letting one be autogenerated creates one without that key and the program does not work.
> There is one Info.plist on the project but it's not on the root of the project because it will overwrite monotouch's one.
> Adding NSPrincipalClass to Info.plist with NSApplication value shows another behaviour.
> The application loads, no NIB is loaded, and debug window shows:
> Loaded assembly: /Library/Frameworks/Mono.framework/Versions/2.6.7/lib/mono/gac/System.Configuration/126.96.36.199__b03f5f7f11d50a3a/System.Configuration.dll [External]
> 2010-11-08 17:19:36.635 iBibliotecary[8448:60f] Could not connect the action buttonPressed: to target of class NSApplication
> 2010-11-08 17:19:36.639 iBibliotecary[8448:60f] Could not connect the action buttonPressed: to target of class NSApplication
> 2010-11-08 17:19:36.640 iBibliotecary[8448:60f] Could not connect the action buttonPressed: to target of class NSApplication
> 2010-11-08 17:19:36.641 iBibliotecary[8448:60f] Could not connect the action buttonPressed: to target of class NSApplication
NSMainNibFile not set gives this error.
On compile this should detect that Info.plist is in another folder and move to the appropriate one, and not require it to be on project's root folder.
If you want to share code between MonoTouch and MonoMac you end duplicating files.
> To recreate, it's easy.
> Create new MonoMac project, move Info.plist to another folder, build&run.
> El 08/11/2010, a las 17:01, Geoff Norton escribió:
>> Could you please file a bug with a test case?
>> On 2010-11-08, at 11:51 AM, Natalia Portillo wrote:
>>> I'm starting to port my application to MonoMac and whenever I run it I just get:
>>> *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '+[AppDelegate sharedApplication]: unrecognized selector sent to class 0x19d1690'
>>> I sincerely don't even know what does this mean, I only know it is raised on NSApplication.Main (args); calling.
>>> Mono-osx mailing list
>>> Mono-osx at lists.ximian.com
> Mono-osx mailing list
> Mono-osx at lists.ximian.com
More information about the Mono-osx