[Mono-winforms-list] OpenFileDialog throwing ArgumentNullException

Bill Medland billmedland@mercuryspeed.com
Tue, 29 Mar 2005 12:04:42 -0800


On March 29, 2005 06:40 am, Alexander Olk wrote:
> Am Montag, den 28.03.2005, 16:36 -0800 schrieb Bill Medland:
> > Can anyone tell me, is this me doing something wrong or is it a current
> > bug in the code?
> >
> > (Assuming I am doing the build properly) mono is the current version
> > updated 10 minutes ago.
> >
> > Test program simply declares an OpenFileDialog
> >
> > Program throws:
> >
> > Unhandled Exception: System.ArgumentNullException: Cannot add null image
> > Parameter name: value
>
> Do me a favour and write a simple test program that uses a MessageBox.
> Does it run ???

Yep!

class ofd01 {
    public static void Main () {
        System.Windows.Forms.MessageBox.Show ("Test");
        System.Windows.Forms.OpenFileDialog ofd = new 
System.Windows.Forms.OpenFileDialog();
    }
}

Pops up the "Test" messagebox and then throws the exception.

> MessageBox uses images from the same resource files. The resources can
> be found in mcs/class/Managed.Windows.Forms/resources.
>
> Open-/SaveFileDialog work fine on Linux (that's where I'm writing and
> testing it...). No problems with an empty ImageList...

My failure is on Linux

>
> Regards
> Alexander Olk
>
> _______________________________________________
> Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-winforms-list

-- 
Bill Medland
mailto:billmedland@mercuryspeed.com
http://webhome.idirect.com/~kbmed