首页 > 编程开发 > Objective-C编程 >
-
c#启动本机程序
using system;
using system.Collections.Generic;
using system.ComponentModel;
using system.Data;
using system.Drawing;
using system.Text;
using system.windows
.Forms;
using system.IO;
using system.Runtime.InteropServices;
using system.Security;
using system.Diagnostics; //命名空间提供特定的类,使您能够与系统进程、事件日志和性能计数器进行交互。
namespace windows
Application1
{
/// <summary>
/// 启动本机系统程序
/// 只需要把程序的exe文件写入Process.Start("")中就行
/// </summary>
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
Process.Start("calc.exe");//计算器
}
private void button2_Click(object sender, EventArgs e)
{
Process.Start("TTPlayer.exe");
}
private void button3_Click(object sender, EventArgs e)
{
Process.Start("IEXPLORE.EXE");
}
}
}