Author: pbartok
Date: 2005-12-08 20:32:29 -0500 (Thu, 08 Dec 2005)
New Revision: 54148

Added:
   trunk/winforms/exception/
   trunk/winforms/exception/Makefile
   trunk/winforms/exception/exception.cs
Log:
- App to test MWF exception handling


Added: trunk/winforms/exception/Makefile
===================================================================
--- trunk/winforms/exception/Makefile   2005-12-09 01:31:59 UTC (rev 54147)
+++ trunk/winforms/exception/Makefile   2005-12-09 01:32:29 UTC (rev 54148)
@@ -0,0 +1,10 @@
+all: exception.exe
+
+exception.exe: exception.cs
+       mcs exception.cs /r:System.Windows.Forms.dll /r:System.Drawing.dll
+
+dotnet: exception.cs
+       csc exception.cs /r:System.Windows.Forms.dll /r:System.Drawing.dll
+
+clean:
+       rm exception.exe -r -f


Property changes on: trunk/winforms/exception/Makefile
___________________________________________________________________
Name: svn:eol-style
   + native

Added: trunk/winforms/exception/exception.cs
===================================================================
--- trunk/winforms/exception/exception.cs       2005-12-09 01:31:59 UTC (rev 
54147)
+++ trunk/winforms/exception/exception.cs       2005-12-09 01:32:29 UTC (rev 
54148)
@@ -0,0 +1,43 @@
+//
+
+using System;
+using System.Drawing;
+using System.Windows.Forms;
+using System.Threading;
+
+namespace testwin
+{
+       public class MainForm : Form
+       {
+               private Button button;
+               private Label label;
+               public MainForm()
+               {
+                       button = new Button();
+                       SuspendLayout();
+                       button.Location = new System.Drawing.Point(40, 32);
+                       button.Text = "Push me to cause an exception";
+                       button.Click += new System.EventHandler(OnClick);
+                       button.Size = new Size(100, 28);
+                       AutoScaleBaseSize = new Size(5, 13);
+                       ClientSize = new System.Drawing.Size(292, 266);
+                       Controls.Add(button);
+                       Text = "Exception test";
+                       label = new Label();
+                       ResumeLayout(false);
+               }
+               
+               [STAThread]
+               public static void Main(string[] args)
+               {
+
+                       Application.Run(new MainForm());
+               }
+               
+               void OnClick(object sender, System.EventArgs e)
+               {
+                       label.BorderStyle = (BorderStyle)1234;
+               }
+       }
+}
+


Property changes on: trunk/winforms/exception/exception.cs
___________________________________________________________________
Name: svn:eol-style
   + native

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to