微软MCAD 70-310 实战百题
题目内容

You are creating an XML Web service named BankCustomer that provides customer information. You write code to keep track of error messages, warning messages, and informational messages while the service is running. You use the Trace class to write the messages to a log file.On test computers, you want to see error messages and warning messages . On deployment computers, you want to see error messages, but not warning messages.Which code segments should you use? (Each correct answer presents part of the solution. Choose two)

2021-12-25

A.Private mySwitch As New TraceSwitch Sub BankCustomermySwitch = New TraceSwitch ("tswitch", "a trace switch") End Sub

B.Public Shared level As New TraceLevel Sub BankCustomerlevel = TraceLevel.ErrorEnd SubC . Trace.WriteLinelf(mySwitch.TraceError,"An error occurred.")Trace.WriteLinelf(mySwitch.TraceWarning,"Warning message")D. Trace.WriteLinelf (level = TraceLevel.Error,"The operation succeeded.u)Trace.WriteLinelf(level = TraceLevel.Warning,"Warning message")E . Trace.WriteLinelf(mySwitch <> Nothing,"An error occurred.")Trace.WriteLinelf(mySwitch <> Nothing,"Warning Message")F.Trace.Writelf(level <> TraceLevel.Off,"An error occurred.")Trace.Writelf(level <> TraceLevel.Off,"Warning Message")

题目答案

试卷相关题目

最新试卷
热门试卷

长理培训客户端 资讯,试题,视频一手掌握

去 App Store 免费下载 iOS 客户端