[Mono-list] System.Windows.Forms test

Willngton Roque willngton at gmail.com
Tue Jul 26 22:45:20 EDT 2005


I usinging Conectiva Linux 10 and mono-1.1.8.2.
This sample ruing ok 

2005/7/26, Santi Serrano <santi.serrano at bigfoot.com>:
> 
> Hi,
> 
> I am trying to compile and execute a simple program that only shows a form
> but I get the folowing error when executing:
> 
> -------------------------------------------------------
> Unhandled Exception: System.TypeInitializationException: An exception was
> thrown by the type initializer for System.Windows.Forms.XplatUI --->
> System.Reflection .TargetInvocationException: Exception has been thrown by
> the target of an invoca tion. ---> System.NotSupportedException: Either
> image format is unknown or you d on't have the required libraries for this
> format.
> in <0x0014a> System.Drawing.GDIPlus:CheckStatus (Status status)
> in <0x000ca> System.Drawing.Image:InitFromStream (System.IO.Stream stream)
> in (wrapper remoting-invoke-with-check) 
> System.Drawing.Image:InitFromStream
> (Sys tem.IO.Stream)
> in <0x00104> System.Drawing.Bitmap:.ctor
> (System.Runtime.Serialization.Serializa tionInfo info, StreamingContext
> context)
> in <0x00000> <unknown method>
> in (wrapper managed-to-native) 
> System.Reflection.MonoCMethod:InternalInvoke
> (obj ect,object[])
> [...]
> -------------------------------------------------------
> 
> The source code:
> 
> -------------------------------------------------------
> using System;
> using System.Windows.Forms;
> 
> public class Form1 : Form
> {
> public static void Main()
> {
> Application.Run(new Form1());
> }
> }
> -------------------------------------------------------
> 
> I am using the ubuntu live mono cd with the following commands:
> 
> mcs Form1.cs -r:System.Windows.Forms -> OK
> mono Form1.exe -> KO
> 
> Thank you for you help.
> Santi.
> 
> _______________________________________________
> Mono-list maillist - Mono-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
> 



-- 
Willngton Roque
willngton at hotmail.com
willngton at gmail.com
http://br.thespoke.net/MyBlog/willngton/MyBlog.aspx
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-list/attachments/20050727/8e88c4f5/attachment.html


More information about the Mono-list mailing list