Hello, The error you get roughly means that the NIB file has not been found.
When developing a Cocoa application with Monobjc, you have to follow the specific directory structure of a Cocoa Application Bundle. I suggest you to read http://www.monobjc.net/index.php?page=anatomy-of-an-application and http://developer.apple.com/documentation/CoreFoundation/Conceptual/CFBundles/Concepts/BundleAnatomy.html to learn about the structure. In most cases, everything that apply to Cocoa can be applied to Monobjc. Regards, Laurent Etiemble 2008/9/25 Miguel De Buf <[EMAIL PROTECTED]>: > Hi all, > > I am new to monobjc (just discovered it), and want to try it out. > Nevertheless, I fail to load a nib. My code always returns > '633579382263870320 [ERROR] NSApplication - Error while loading the NIB > file'. > > I am on MacOSX 10.4.11 (Tiger) and have mono 1.9.1 installed (latest > version). I downloaded monobjc-2.0.272.0 and use the assemblies from under > the dist/1.0/ folder. I write and compile the code in visual studio > (parallels) on a shared folder on the mac. From that shared folder, I > simply run the assembly. > > Here is my code (note that it works when using cocoa-sharp). > > using System; > using System.Collections.Generic; > using System.Text; > using Monobjc; > using Monobjc.Cocoa; > using Cocoa; > > namespace monobjc_menulet > { > class Program > { > static void Main(string[] args) > { > runMonobjc(); > //runCocoaSharp(); > } > > private static void runCocoaSharp() > { > Application.Init(); > Application.LoadNib("Menulet.nib"); > Application.Run(); > } > > private static void runMonobjc() > { ObjectiveCRuntime.LoadFramework("Cocoa"); > ObjectiveCRuntime.Initialize(); > > NSApplication.Bootstrap(); > NSApplication.LoadNib("Menulet.nib"); > NSApplication.RunApplication(); > } > > } > } > > And this is the output I get on the command line : > > [EMAIL PROTECTED]:~/monobjc-menulet/monobjc-menulet/bin/Debug $ ls > Menulet.nib cocoa-sharp.dll > monobjc-menulet.vshost.exe > Monobjc.Cocoa.dll monobjc-menulet.exe > Monobjc.dll monobjc-menulet.pdb > [EMAIL PROTECTED]:~/monobjc-menulet/monobjc-menulet/bin/Debug $ mono > monobjc-menulet.exe > 633579391323136830 [ERROR] NSApplication - Error while loading the NIB file > ^C > [EMAIL PROTECTED]:~/monobjc-menulet/monobjc-menulet/bin/Debug $ > > Does anyone of you knows why this goes wrong ? > Many thanks in advance, > Miguel > >