1
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Windows.Forms;
using System.Diagnostics;
namespace process
{
public partial class MainForm
{
[STAThread]
public static void Main(string[] args)
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new MainForm());
}
public MainForm()
{
InitializeComponent();
}
void Button1Click(object sender, System.EventArgs e)
{
Process.Start("IExplore.exe","http://www.baidu.com/");
}
void Button2Click(object sender, System.EventArgs e)
{
Process.Start("explorer.exe");
}
void Button3Click(object sender, System.EventArgs e)
{
Process.Start("EXCEL.exe");
}
void Button4Click(object sender, System.EventArgs e)
{
Process.Start("dvdplay.exe");
}
}
}
2.
private void bt_Search_Click(object sender, EventArgs e)
{
if (this.rbtBaidu.Checked)
{
if ((this.textBox1.Text == null) || (this.textBox1.Text == ""))
{
Process.Start("http://www.baidu.com/");
}
else
{
Process.Start(" http://www.baidu.com/baidu?word=" + this.textBox1.Text);
}
}
启动应用程序的桌面软件
最新推荐文章于 2024-11-06 11:25:03 发布