black

MCPD(70-536)

登录

多项选择题

您开发一个名为FileService 的服务应用程序。您将该服务应用程序部署到网络上的多台服务器。
您执行以下代码段。(包括的行号仅供参考。)
01 public void StartService(string serverName){
02 ServiceController crtl = new
03 ServiceController(" Certkiller App29");
04 if (crtl.Status == ServiceControllerStatus.Stopped){
05 }
06 }
您需要开发一个例程,如果FileService 停止,该例程将启动它。该例程必须在由serverName 输入参数确定的服务器上启动FileService。
您应该将哪两行代码添加到代码段?()(每个正确答案都仅给出了部分解决方案。请选择两个答案。)
Servername是指机器的名字。

A.在03 行和04 行之间插入以下代码行:crtl.ServiceName = serverName;
B.在03 行和04 行之间插入以下代码行:crtl.MachineName = serverName;
C.在03 行和04 行之间插入以下代码行:crtl.Site.Name = serverName;
D.在04 行和05 行之间插入以下代码行:crtl.Continue();
E.在04 行和05 行之间插入以下代码行:crtl.Start();
F.在04 行和05 行之间插入以下代码行:crtl.ExecuteCommand(0);

相关考题

单项选择题 现在您在开发一个类库,其中某个代码片段需要访问系统的环境变量。 当调用堆栈中处于较高位置的调用方不具有当前实例所指定的权限时您需要强制使用SecurityException异常。您会调用下面哪个方法?()

单项选择题 You are loading a new assembly into an application. You need to override the default evidence for the assembly. You require the common language runtime (CLR) to grant the assembly a permission set,as if the assembly were loaded from the local intranet zone.  You need to build the evidence collection. Which code segment should you use?()

单项选择题 你是Certikller.com网站的应用程序开发人员,你正在编写一个代码段,你必须确保数据包含在一个叫做Setting.dat的独立的文件中存储。以字符串的形式返回。 Settings.dat在机器域中。 选择能够达成目标的代码段()

All Rights Reserved 版权所有©考试题库网(kstiku.com)

备案号:湘ICP备14005140号-3

经营许可证号:湘B2-20140064