请问状态栏这个控件怎么用啊,我已经托到form里了,可是不会用,不知道怎么写,给我个小例子就行了,平台C#2005
解决方案 »
- 求:asp.net(c#)程序版本升级更新的实现代码
- 如何通过Message-ID打开相应的email
- 寻求多线程帮助(急),进来我传文件给你
- 如何在同一个控件实现不同字体
- 如何把Excel数据导入到sql2000中(用代码)
- 各位能人 帮帮忙啊 C# 操作cmd.exe 的问题 也用来驱动器其他程序
- 程序退出后,怎么保存修改后的控件的值
- 请问 .NET 中可以开发用 RunDll32 调用的 DLL 吗?怎样做?
- 请问,如何对一个网站的内容进行实时的监控,如果它上面添加了一条新闻,我就能的到其标题和连接!!!!
- 怎样在c#种调用api函数?怎样获得鼠标在活动窗口中的坐标
- string.substring(1,1)返回空还是0?
- .net web.config错误问题,求各路搞手帮个,不分不够再加,
using System.Text;
using System.Windows.Forms;namespace WindowsApplication4
{
public class Form1 : Form
{
private StatusStrip statusStrip1;
private ToolStripStatusLabel toolStripStatusLabel1;
public Form1()
{
InitializeComponent();
}
[STAThread]
static void Main()
{
Application.EnableVisualStyles();
Application.Run(new Form1());
} private void InitializeComponent()
{
statusStrip1 = new System.Windows.Forms.StatusStrip();
toolStripStatusLabel1 = new System.Windows.Forms.ToolStripStatusLabel();
statusStrip1.SuspendLayout();
SuspendLayout();
//
// The following code example demonstrates the syntax for setting
// various StatusStrip properties.
statusStrip1.Dock = System.Windows.Forms.DockStyle.Top;
statusStrip1.GripStyle = System.Windows.Forms.ToolStripGripStyle.Visible;
statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
toolStripStatusLabel1});
statusStrip1.LayoutStyle = System.Windows.Forms.ToolStripLayoutStyle.HorizontalStackWithOverflow;
statusStrip1.Location = new System.Drawing.Point(0, 0);
statusStrip1.Name = "statusStrip1";
statusStrip1.ShowItemToolTips = true;
statusStrip1.Size = new System.Drawing.Size(292, 22);
statusStrip1.SizingGrip = false;
statusStrip1.Stretch = false;
statusStrip1.TabIndex = 0;
statusStrip1.Text = "statusStrip1";
//
// toolStripStatusLabel1
//
toolStripStatusLabel1.Name = "toolStripStatusLabel1";
toolStripStatusLabel1.Size = new System.Drawing.Size(109, 17);
toolStripStatusLabel1.Text = "toolStripStatusLabel1";
//
// Form1
//
ClientSize = new System.Drawing.Size(292, 273);
Controls.Add(statusStrip1);
Name = "Form1";
statusStrip1.ResumeLayout(false);
statusStrip1.PerformLayout();
ResumeLayout(false);
PerformLayout(); }
}
}
public Form1()
{
InitializeComponent();
StatusStrip statusStrip1 = new System.Windows.Forms.StatusStrip();
ToolStripStatusLabel toolStripStatusLabel1 = new System.Windows.Forms.ToolStripStatusLabel();
//
// statusStrip1
//
statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
toolStripStatusLabel1});
statusStrip1.Location = new System.Drawing.Point(0, 244);
statusStrip1.Name = "statusStrip1";
statusStrip1.Size = new System.Drawing.Size(292, 22);
statusStrip1.TabIndex = 2;
statusStrip1.Text = "statusStrip1";
statusStrip1.ItemClicked += new System.Windows.Forms.ToolStripItemClickedEventHandler(this.statusStrip1_ItemClicked);
//
// toolStripStatusLabel1
//
toolStripStatusLabel1.Name = "toolStripStatusLabel1";
toolStripStatusLabel1.Size = new System.Drawing.Size(131, 17);
toolStripStatusLabel1.Text = "toolStripStatusLabel1";
toolStripStatusLabel1.Text = "你要显示的内容"; this.Controls.Add(statusStrip1);
}----------------------------------------
toolStripStatusLabel1.Text = "你要显示的内容";