System Information

Impossible Is Nothing...

导航

2005年11月14日 #

asp.net控制Sql Server服务的启动与停止.

摘要: 首先在解决方案资源管理器中添加引用System.ServiceProcess.dll然后在.cs中using System.ServiceProcess;然后在事件中写代码: ServiceController sc=new ServiceController("MSSQLSERVER"); if(sc.Status==ServiceControllerStatus.Stopped) ... 阅读全文

posted @ 2005-11-14 22:56 SysInfo 阅读(490) 评论(1) 推荐(0) 编辑