总结自己在.NET中常用的方法
来源:互联网 发布:鲁班软件和广联达 编辑:程序博客网 时间:2024/06/05 17:35
//打开IE并跳到指定的网页
ProcessStartInfo startInfo = new ProcessStartInfo("IExplore.exe");
startInfo.Arguments = "www.vuel.cn";
Process process1 = new Process();
process1.StartInfo = startInfo;
process1.Start();
//打开计事本
System.Diagnostics.Process.Start("notepad.exe");
//将字符串写到粘贴板
System.Windows.Forms.Clipboard.SetDataObject(textBox1.Text);
//清空粘贴板
System.Windows.Forms.Clipboard.Clear();
//将texBox设为只读
textBox.ReadOnly = true;
//将字符串按指定的基数转为Int型
Convert.ToInt32("111111111",2) int可为8,16之类,右边函数既为255
//将long类按指定的基数转为String型
Convert.ToString(255,2) int可为8,16之类,右边函数既为"1111111"
//将String转为int型
int.Parse(string str)
//离开控件时产生的事件
this.Textbox_Leave += new System.EventHandler(this.Textbox_Leave);
Textbox_Leave(object sender,EventArgs 3)
//Forms窗口的IsMdiContainer属性为true时,窗口为主窗口(MDI容器)
//弹出信息框
MessageBox.Show( "您输入的用户号或密码不正确!");
if (MessageBox.Show("确实要退出系统吗?","询问",MessageBoxButtons.YesNo) == DialogResult.Yes)
{
this.Close();
}
ProcessStartInfo startInfo = new ProcessStartInfo("IExplore.exe");
startInfo.Arguments = "www.vuel.cn";
Process process1 = new Process();
process1.StartInfo = startInfo;
process1.Start();
//打开计事本
System.Diagnostics.Process.Start("notepad.exe");
//将字符串写到粘贴板
System.Windows.Forms.Clipboard.SetDataObject(textBox1.Text);
//清空粘贴板
System.Windows.Forms.Clipboard.Clear();
//将texBox设为只读
textBox.ReadOnly = true;
//将字符串按指定的基数转为Int型
Convert.ToInt32("111111111",2) int可为8,16之类,右边函数既为255
//将long类按指定的基数转为String型
Convert.ToString(255,2) int可为8,16之类,右边函数既为"1111111"
//将String转为int型
int.Parse(string str)
//离开控件时产生的事件
this.Textbox_Leave += new System.EventHandler(this.Textbox_Leave);
Textbox_Leave(object sender,EventArgs 3)
//Forms窗口的IsMdiContainer属性为true时,窗口为主窗口(MDI容器)
//弹出信息框
MessageBox.Show( "您输入的用户号或密码不正确!");
if (MessageBox.Show("确实要退出系统吗?","询问",MessageBoxButtons.YesNo) == DialogResult.Yes)
{
this.Close();
}
- 总结自己在.NET中常用的方法
- NET开发中你可能会用到的常用方法总结。
- .NET开发中你可能会用到的常用方法总结
- .NET开发中你可能会用到的常用方法总结
- NET开发中你可能会用到的常用方法总结
- NET开发中你可能会用到的常用方法总结
- .NET开发中你可能会用到的常用方法总结
- .NET开发中你可能会用到的常用方法总结
- .net开发中自己遇到的问题自己解决的方法总结
- vim自己总结的常用方法
- 在Asp.Net中发送邮件的常用方法:
- .net中常用小方法总结
- ASP.NET中常用方法总结
- 在.net中序列化读写xml方法的总结
- 在.net中序列化读写xml方法的总结
- 在.net中序列化读写xml方法的总结
- 在.net中序列化读写xml方法的总结
- 在.net中序列化读写xml方法的总结
- 我最恐惧的事情是竞争力的丧失
- C# 调用SetROP2实现橡皮线效果
- [转]分组报表中,如何让组名字段只显示中间的一行 [http://blog.csdn.net/xwdd129/archive/2006/05/29/760661.aspx]
- “建站三剑”——中小网站的建站法宝
- 软件测试面试题整理
- 总结自己在.NET中常用的方法
- javascript小技巧&&JavaScript[对象.属性]集锦
- Oracle Responds to BEA Letter - An email from President of Oracle
- 如何加速你的PHP程序
- JdbcTemplate
- 在客户端浏览器中显示进度条来显示页面正在装载
- 适合中国国情的BREW小程序开发流程—与美国高通和联通博路接轨
- I will be back——David Trezeguet
- 防止PHP中SQL注入实现代码