Create file services.cs
/************** services.cs ****************/
public class Form1 : System.Windows.Forms.Form {
public Form1() {
InitializeComponent();
}
private void InitializeComponent() {
this.AutoScaleBaseSize = new System.Drawing.Size(6, 15);
this.ClientSize = new System.Drawing.Size(292, 260);
this.Name = "Form1";
this.Text = "Form1";
}
static void Main() {
System.Windows.Forms.Application.Run(new Form1());
}
}
/**************** end of services.cs ***********/
Compile it via csc: > csc services.cs
Run exe: > services.exe
Form will appear, but look will be windows classic even if you have
Windows XP theme selected for your display. Rename exe to
"servicess.exe" for example and, when you run app, you will have
desired XP look of your app. Does anyone have reasonable explanation
for this strange behaviour?
Thanx