Groups
Groups
Sign in
Groups
Groups
C# Guide
Conversations
About
Send feedback
Help
C#作业样本⑹-- GUI Ⅱ
1 view
Skip to first unread message
bluefin
unread,
Jun 6, 2008, 4:42:45 PM
6/6/08
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to C# Guide
(注:以下教程适合初学者,介绍C#。下载.NET Framework 2.0 版本到你的Windows
2000 SP4 或者Windows XP SP2。)
①打开notepad.exe
②输入以下内容:
using System.Windows.Forms;
public class winFrm : Form
{
public static void Main( string [ ] args )
{
winFrm myForm = new winFrm ( );
myForm.Text = "myForm";
Application.Run ( myForm );
}
}
③储存名档为winFrm.cs
④设计一个Image 名为App.ico,根据以下Property value:
Width/Height = 32/32 pixels
Resolution (Horz/Vert) = 96/96 dpi
Bith depth= 32
Frame Count= 1
⑤进入"C:\Windows\Microsoft.NET\Framework\v2.0.50727" 里头,执行csc.exe
如下:
csc.exe /target:winexe /win32icon:App.ico /nologo winFrm.cs [ 回车
键 ]
这时它再也不会显示以下讯息了:
Microsoft (R) Visual C# 2005 Compiler version 8.00.50727.42
for Microsoft (R) Windows (R) 2005 Framework version 2.0.50727
Copyright (C) Microsoft Corporation 2001-2005. All rights reserved.
⑥输入dir winFrm.*
这时它会显示以下讯息:
winFrm.cs
winFrm.exe
注:若你见不到winFrm.exe, 你一定要先除错winFrm.cs,一直得到为止。
⑥输入winfrm.exe
这个窗口以“C#作业样本⑵”有何特徵呢?请互相回帖、分享心得,获益不浅!
Reply all
Reply to author
Forward
0 new messages