网友您好, 请在下方输入框内输入要搜索的题目:

题目内容 (请给出正确答案)

You are creating a Windows Forms application by using the .NET Framework 3.5. The application requires a thread that accepts a single integer parameter.    You write the following code segment (Line numbers are included for reference only.) Thread myThread = new Thread(new ParameterizedThreadStart(DoWork)) ;  myThread.Start(100); You need to declare the method signature of the DoWork method.   Which method signature should you use?()

  • A、public void DoWork();
  • B、public void DoWork(int nCounter);
  • C、public void DoWork(object oCounter);
  • D、public void DoWork(Delegate oCounter);

参考答案

更多 “ You are creating a Windows Forms application by using the .NET Framework 3.5. The application requires a thread that accepts a single integer parameter.    You write the following code segment (Line numbers are included for reference only.) Thread myThread = new Thread(new ParameterizedThreadStart(DoWork)) ;  myThread.Start(100); You need to declare the method signature of the DoWork method.   Which method signature should you use?()A、public void DoWork();B、public void DoWork(int nCounter);C、public void DoWork(object oCounter);D、public void DoWork(Delegate oCounter);” 相关考题
考题 You use Microsoft .NET Framework 4 to create a Windows Forms client application.You write the following code segment.The application contains a form of type Form1 that contains a FormSettings object named frmSettings1.You need to maintain the user‘s form size preference each time the user executes the application.Which code segment should you use? ()A.B.C.D.

考题 You are developing a Windows Communication Foundation (WCF) service.You enable message logging, trace listeners, activity propagation, and tracing on the trace sources.You have the following code segment in the client application. (Line numbers are included for reference only.)01 Guid multiCallActivityId = Guid.NewGuid();02 TraceSource ts = new TraceSource(Multicall);03 Trace.CorrelationManager.ActivityId = multiCallActivityId;04You encounter errors when your client application consumes the service.You need to ensure that your client application can correlate tracing information with the service.Which code segment should you add at line 04?()A.B.C.D.

考题 You are creating a Windows Forms application for a financial service provider by using the .NET Framework 3.5. You have to implement a multiple document interface (MDI) in the application to allow users to open multiple financial documents simultaneously.You need to ensure that whenever the child MDI form is created, the application displays a message in the title bar of the parent MDI that a child form has received focus.   What should you do?()A、Implement theActivated eventB、Implement the MdiChildActivate eventC、Override the OnParentVisibleChanged methodD、Override the OnParentBindingContextChanged method

考题 You use Microsoft .Net Framework 4 to create a Windows Form application. You created a new application, you then wrote the code below: Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture Which of the following options are TRUE? ()A、The user interface will make use of the currently configured culture settings in the Control Panel at present.B、The user interface will make use of new culture settings.C、The user interface will make use of the culture settings that were installed with the operating system.

考题 You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5. You create a page that contains the following code fragment:       You write the following code segment in the code-behind file for the page:   void BindData(object sender, EventArgs e) {   lstLanguages.DataSource =  CultureInfo.GetCultures(CultureTypes.AllCultures);   lstLanguages.DataTextField = "EnglishName";  lstLanguages.DataBind();   }   You need to ensure that the lstLanguages ListBox control maintains the selection of the user during postback.  Which line of code should you insert in the constructor of the page?()A、this.Init += new EventHandler(BindData); B、this.PreRender += new EventHandler(BindData); C、lstLanguages.PreRender += new EventHandler(BindData); D、lstLanguages.SelectedIndexChanged += new EventHandler(BindData);

考题 You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5. When you access the application in a Web browser, you receive the following error message: "Service Unavailable".  You need to access the application successfully.  What should you do?()A、Start Microsoft IIS 6.0. B、Start the Application pool. C、Set the .NET Framework version. D、Add the Web.config file for the application.

考题 You are creating a Windows application for graphical image processing by using the .NET Framework 3.5. You create an image processing function and a delegate.You plan to invoke the image processing function by using the delegate.You need to ensure that the calling thread meets the following requirements:  (1)It is not blocked when the delegate is running   (2)It is notified when the delegate is complete What should you do?()A、Call the Invoke method of the delegate.B、Call the BeginInvoke and EndInvoke methods of the delegate in the calling thread.C、Call the BeginInvoke method by specifying a callback method to be executed when the delegate is complete.Call the EndInvoke method in the callback method.D、Call the BeginInvoke method by specifying a callback method to be executed when the delegate is complete.Call the EndInvoke method of the delegate in the calling thread.

考题 You are creating a Windows Forms application by using the .NET Framework 3.5. You plan to develop a new control for the application.You need to ensure that the control extends the TreeView control by adding a custom node tag and a highlight color.What should you do?()A、Override the OnPaint method.B、Write a code segment in the DrawNode event handler to specify the highlight color.C、Set the DrawMode property of the control to OwnerDrawAll, and then implement a custom DrawNode event handler.D、Set the DrawMode property of the control to OwnerDrawText,and then implement a custom DrawNode event handler.

考题 You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.  You create a custom Web user control named SharedControl. The control will be compiled as a library.  You write the following code segment for the SharedControl control. (Line numbers are included for  reference only.)  01 protected override void OnInit(EventArgs e) 02 {  03 base.OnInit(e);  04  05 }  All the master pages in the ASP.NET application contain the following directive.  %@ Master Language="C#" EnableViewState="false" %  You need to ensure that the state of the SharedControl control can persist on the pages that reference a  | English | Chinese | Japan | Korean | - 87 - Test Information Co., Ltd. All rights reserved. master page.  Which code segment should you insert at line 04?()A、Page.RegisterRequiresPostBack(this);B、Page.RegisterRequiresControlState(this);C、Page.UnregisterRequiresControlState(this);D、Page.RegisterStartupScript("SharedControl","server");

考题 You use Microsoft .NET Framework 4 to create a Windows Forms application. You need to allow the user interface to use the currently configured culture settings in the Control Panel. Which code segment should you use?()A、Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture;B、Thread.CurrentThread.CurrentCulture = Thread.CurrentThread.CurrentUICulture;C、Thread.CurrentThread.CurrentUICulture = CultureInfo.InstalledUICulture;D、Thread.CurrentThread.CurrentCulture = CultureInfo.InstalledUICulture;

考题 You use Microsoft .NET Framework 4 to create a Windows Forms application. You created a new application, you then wrote the code below: Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture; Which of the following options are TRUE?()A、The user interface will make use of the currently configured culture settings in the Control Panel at present.B、The user interface will make use of new culture settings.C、The user interface will have no culture settings.D、The user interface will make use of the culture settings that were installed with the operating system.

考题 You are creating a Windows Forms application by using the .NET Framework 3.5.You plan to develop a new control for the application. You need to ensure that the control extends the DataGridView control by allowing the cells to contain multicolored text. What should you do?()A、Override the OnPaint method.B、Write a code segment to handle the CellPainting event.C、Write a code segment to handle the CellParsing event.D、Write a code segment to handle the RowPostPaint event.

考题 You are working with a Windows Communication Foundation (WCF) client application that has a generated proxy named SampleServiceProxy.When the client application is executing, in line 04 of the following code, the channel faults (Line numbers are included for reference only.) 01 SampleServiceProxy proxy = new SampleServiceProxy( ); 02 try 03 { 04 proxy.ProcessInvoice(invoice); 05 } 06 catch 07 { 08 if(proxy.State == CommunicationState.Faulted) 09 { 10 ... 11 } 12 } 13 proxy.UpdateCustomer(customer);You need to return proxy to a state in which it can successfully execute the call in line 13.Which code segment should you use at line 10?()A、proxy.Close();B、proxy = new SampleServiceProxy();C、proxy.Abort();D、proxy.Open();

考题 You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.  You create a custom Web user control named SharedControl. The control will be compiled as a library.  You write the following code segment for the SharedControl control. (Line numbers are included for reference only.)  01 Protected Overloads Overrides Sub OnInit(ByVal e As EventArgs)  02 MyBase.OnInit(e)  03  04 End Sub  All the master pages in the ASP.NET application contain the following directive.  %@ Master Language="VB" EnableViewState="false" %  You need to ensure that the state of the SharedControl control can persist on the pages that reference a master page.  Which code segment should you insert at line 03?()A、Page.RegisterRequiresPostBack(Me)B、Page.RegisterRequiresControlState(Me)C、Page.UnregisterRequiresControlState(Me)D、Page.RegisterStartupScript("SharedControl", "server")

考题 You create Windows Forms applications by using the .NET Framework 3.5. You plan to use a setup project to deploy a new Windows Forms application.The application uses a component that requires the Microsoft NET Framework 1.1.You need to create a launch condition so that the application can be deployed on client computers.   What should you do?()A、Use the Depth property.B、Use the Version property.C、Use the MinVersion property.D、Use the ComponentID property.

考题 You create a Microsoft ASP.NET Web application by using the Microsoft .NET Framework version 3.5.  When you review the application performance counters, you discover that there is an unexpected increase in the value of the Application Restarts counter. You need to identify the reasons for this increase.  What are three possible reasons that could cause this increase?()A、Restart of the Microsoft IIS 6.0 host.B、Restart of the Microsoft Windows Server 2003 that hosts the Web application.C、Addition of a new assembly in the Bin directory of the application.D、Addition of a code segment that requires recompilation to the ASP.NET Web application.E、Enabling of HTTP compression in the Microsoft IIS 6.0 manager for the application.F、Modification to the Web.config file in the system.web section for debugging the application.

考题 You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5. You create a custom Web user control named SharedControl. The control will be compiled as a library.  You write the following code segment for the SharedControl control: 01 protected override void OnInit(EventArgs e)   02 {   03   base.OnInit(e);   04 ►  05 }    All the master pages in the ASP.NET application contain the following directive. %@ Master Language="C#" EnableViewState="false" %    You need to ensure that the state of the SharedControl control can persist on the pages that reference a master page.  Which code segment should you insert at line 04?()A、Page.RegisterRequiresPostBack(this); B、Page.RegisterRequiresControlState(this); C、Page.UnregisterRequiresControlState(this); D、Page.RegisterStartupScript("SharedControl","server");

考题 You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5. The application contains a DataSourceControl named CategoriesDataSource that is bound to a Microsoft SQL Server 2005 table. The CategoryName column is the primary key of the table. You write the following code fragment in a FormView control:   01    02   Category:   03      09      10     You need to ensure that the changes made to the CategoryID field can be written to the database.  Which code fragment should you insert at line 04?()A、SelectedValue='%# Eval("CategoryID") %' B、SelectedValue='%# Bind("CategoryID") %' C、SelectedValue='%# Eval("CategoryName") %' D、SelectedValue='%# Bind("CategoryName") %'

考题 单选题You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5. The application allows users to post comments to a page that can be viewed by other users. You add a SqlDataSource control named SqlDS. You write the following code segment:   01 private void SaveComment()   02 {   03   string ipaddr;   04 ►  05   SqlDS1.InsertParameters["IPAddress"].DefaultValue = ipaddr;   06   ...  07   SqlDS1.Insert();   08 }   You need to ensure that the IP Address of each user who posts a comment is captured alongwith the user’s comment.  Which code segment should you insert at line 04?()A ipaddr = Server[REMOTE_ADDR].ToString(); B ipaddr = Session[REMOTE_ADDR].ToString(); C ipaddr = Application[REMOTE_ADDR].ToString(); D ipaddr = Request.ServerVariables[REMOTE_ADDR].ToString();

考题 单选题You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5. You create a custom Web user control named SharedControl. The control will be compiled as a library.  You write the following code segment for the SharedControl control: 01 protected override void OnInit(EventArgs e)   02 {   03   base.OnInit(e);   04 ►  05 }    All the master pages in the ASP.NET application contain the following directive.     You need to ensure that the state of the SharedControl control can persist on the pages that reference a master page.  Which code segment should you insert at line 04?()A Page.RegisterRequiresPostBack(this); B Page.RegisterRequiresControlState(this); C Page.UnregisterRequiresControlState(this); D Page.RegisterStartupScript(SharedControl,server);

考题 单选题You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.  You create a custom Web user control named SharedControl. The control will be compiled as a library.  You write the following code segment for the SharedControl control. (Line numbers are included for reference only.)  01 Protected Overloads Overrides Sub OnInit(ByVal e As EventArgs)  02 MyBase.OnInit(e)  03  04 End Sub  All the master pages in the ASP.NET application contain the following directive.    You need to ensure that the state of the SharedControl control can persist on the pages that reference a master page.  Which code segment should you insert at line 03?()A Page.RegisterRequiresPostBack(Me)B Page.RegisterRequiresControlState(Me)C Page.UnregisterRequiresControlState(Me)D Page.RegisterStartupScript(SharedControl, server)

考题 单选题You are creating a Windows Forms application by using the .NET Framework 3.5. You plan to develop a new control for the application.You need to ensure that the control extends the TreeView control by adding a custom node tag and a highlight color.What should you do?()A Override the OnPaint method.B Write a code segment in the DrawNode event handler to specify the highlight color.C Set the DrawMode property of the control to OwnerDrawAll, and then implement a custom DrawNode event handler.D Set the DrawMode property of the control to OwnerDrawText,and then implement a custom DrawNode event handler.

考题 单选题You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5. You create a Web form in the application by using the following code fragment:   01     02 protected void Button_Handler(object sender, EventArgs e)   03 {   04   // some long-processing operation.  05 }   06    07  A AB BC CD D

考题 单选题You use Microsoft .NET Framework 4 to create a Windows Forms application. You need to allow the user interface to use the currently configured culture settings in the Control Panel. Which code segment should you use?()A Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture;B Thread.CurrentThread.CurrentCulture = Thread.CurrentThread.CurrentUICulture;C Thread.CurrentThread.CurrentUICulture = CultureInfo.InstalledUICulture;D Thread.CurrentThread.CurrentCulture = CultureInfo.InstalledUICulture;

考题 单选题You are creating a Windows Forms application by using the .NET Framework 3.5.You plan to develop a new control for the application.You need to ensure that the control extends the DataGridView control by allowing the cells to contain multicolored text.What should you do?()A Override the OnPaint method.B Write a code segment to handle the CellPainting event.C Write a code segment to handle the CellParsing event.D Write a code segment to handle the RowPostPaint event.

考题 单选题You use Microsoft .NET Framework 4 to create a Windows Forms application. You created a new application, you then wrote the code below: Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture; Which of the following options are TRUE?()A The user interface will make use of the currently configured culture settings in the Control Panel at present.B The user interface will make use of new culture settings.C The user interface will have no culture settings.D The user interface will make use of the culture settings that were installed with the operating system.

考题 单选题You use Microsoft .Net Framework 4 to create a Windows Form application. You created a new application, you then wrote the code below: Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture Which of the following options are TRUE? ()A The user interface will make use of the currently configured culture settings in the Control Panel at present.B The user interface will make use of new culture settings.C The user interface will make use of the culture settings that were installed with the operating system.