KillTest 质量更高 服务更好 学习资料 半年免费更新服务

Similar documents
KillTest 质量更高 服务更好 学习资料 半年免费更新服务

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

epub83-1

2 WF 1 T I P WF WF WF WF WF WF WF WF 2.1 WF WF WF WF WF WF

1 Framework.NET Framework Microsoft Windows.NET Framework.NET Framework NOTE.NET NET Framework.NET Framework 2.0 ( 3 ).NET Framework 2.0.NET F

Microsoft PowerPoint - ch6 [相容模式]

6-1 Table Column Data Type Row Record 1. DBMS 2. DBMS MySQL Microsoft Access SQL Server Oracle 3. ODBC SQL 1. Structured Query Language 2. IBM

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

untitled

VB控件教程大全

Chn 116 Neh.d.01.nis

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

基于ECO的UML模型驱动的数据库应用开发1.doc

AL-MX200 Series

<4D F736F F F696E74202D20C8EDBCFEBCDCB9B9CAA6D1D0D0DEBDB2D7F92E707074>

Olav Lundström MicroSCADA Pro Marketing & Sales 2005 ABB - 1-1MRS755673

untitled

概述

untitled

untitled

untitled

Value Chain ~ (E-Business RD / Pre-Sales / Consultant) APS, Advanc

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

EJB-Programming-4-cn.doc

Chapter 9: Objects and Classes

Preface This guide is intended to standardize the use of the WeChat brand and ensure the brand's integrity and consistency. The guide applies to all d

Fun Time (1) What happens in memory? 1 i n t i ; 2 s h o r t j ; 3 double k ; 4 char c = a ; 5 i = 3; j = 2; 6 k = i j ; H.-T. Lin (NTU CSIE) Referenc

Visual Basic D 3D

Microsoft Word - template.doc

Guide to Install SATA Hard Disks

软件测试(TA07)第一学期考试

untitled

27 :OPC 45 [4] (Automation Interface Standard), (Costom Interface Standard), OPC 2,,, VB Delphi OPC, OPC C++, OPC OPC OPC, [1] 1 OPC 1.1 OPC OPC(OLE f

ch_code_infoaccess

Oracle 4

untitled

AL-M200 Series

untitled

ebook140-9

EJB-Programming-3.PDF

K7VT2_QIG_v3

Windows XP

OOAD PowerDesigner OOAD Applying PowerDesigner CASE Tool in OOAD PowerDesigner CASE Tool PowerDesigner PowerDesigner CASE To

untitled

ebook46-23

穨control.PDF

Microsoft Word 記錄附件

第一章 章标题-F2 上空24,下空24

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

Serial ATA ( Silicon Image SiI3114)...2 (1) SATA... 2 (2) B I O S S A T A... 3 (3) RAID BIOS RAID... 5 (4) S A T A... 8 (5) S A T A... 10

投影片 1

Microsoft Office SharePoint Server MOSS Web SharePoint Web SharePoint 22 Web SharePoint Web Web SharePoint Web Web f Lists.asmx Web Web CAML f

Oracle Database 10g: SQL (OCE) 的第一堂課

untitled

國 立 政 治 大 學 教 育 學 系 2016 新 生 入 學 手 冊 目 錄 表 11 國 立 政 治 大 學 教 育 學 系 博 士 班 資 格 考 試 抵 免 申 請 表 論 文 題 目 申 報 暨 指 導 教 授 表 12 國 立 政 治 大 學 碩 博 士 班 論

WebSphere Studio Application Developer IBM Portal Toolkit... 2/21 1. WebSphere Portal Portal WebSphere Application Server stopserver.bat -configfile..

Microsoft Word - Final Exam Review Packet.docx

Microsoft Word - ch04三校.doc

coverage2.ppt

Socket Socket TcpClient Socket.Connect TcpClient.Connect Socket.Send / Receive NetworkStream 6-5

3 Driver do Microsoft Access (*.mdb) hisdata IFIX 1.4

untitled

PowerPoint Presentation

Microsoft Word - Functional_Notes_3.90_CN.doc

Windows RTEMS 1 Danilliu MMI TCP/IP QEMU i386 QEMU ARM POWERPC i386 IPC PC104 uc/os-ii uc/os MMI TCP/IP i386 PORT Linux ecos Linux ecos ecos eco

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

Microsoft Word - 第3章.doc

Chapter 2

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

59 1 CSpace 2 CSpace CSpace URL CSpace 1 CSpace URL 2 Lucene 3 ID 4 ID Web 1. 2 CSpace LireSolr 3 LireSolr 3 Web LireSolr ID

Important Notice SUNPLUS TECHNOLOGY CO. reserves the right to change this documentation without prior notice. Information provided by SUNPLUS TECHNOLO

入學考試網上報名指南

CHAPTER VC#

Progress Report of BESIII Slow Control Software Development

CHAPTER 1

支付宝2011年 IT资产与费用预算

mvc

RUN_PC連載_8_.doc

IP505SM_manual_cn.doc

目錄... I... III... V Chapter 1 ADO.NET ADO.NET ADO.NET DataSet NET Framework Data Provide

ÐÅÏ¢¼¼Êõ·þÎñ ÔËÐÐά»¤ µÚ1²¿·Ö£ºÍ¨ÓÃÒªÇ󣨳ö°æÇ°¸å£©

目錄

( Version 0.4 ) 1

Chapter 9: Objects and Classes

Microsoft Word - 新加坡手冊封面.docx

RunPC2_.doc

2 ADO.NET Internet 1.2

Business Objects 5.1 Windows BusinessObjects 1

Android Robert C.C. Huang Oscar F.Y. Liu Peter C.L. Hsieh 2011/03/21

untitled

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

Computer Architecture

Microsoft Word - (web)_F.1_Notes_&_Application_Form(Chi)(non-SPCCPS)_16-17.doc

ebook140-8

Junos Pulse Mobile Security R1 2012, Juniper Networks, Inc.

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

CA KPIF 2008 Nov. KFHP/KPIC Application Chinese Prospect

untitled

Transcription:

KillTest 质量更高 服务更好 学习资料 http://www.killtest.cn 半年免费更新服务

Exam : 70-566 Title : Upgrade: Transition your MCPD Windows Developer Skills to MCPD Windows Developer 3 Version : Demo 1 / 14

1.You are creating a Windows Forms application by using the.net Framework 3.5. The application requires a form to display a clock. You need to create a circular form to display the clock. Which code segment should you use? A. this.formborderstyle = System.Windows.Forms.FormBorderStyle.None; System.Drawing.Drawing2D.GraphicsPath path = new System.Drawing.Drawing2D.GraphicsPath(); path.addellipse(0, 0, this.width, this.height); Region reg = new Region(); this.region = reg; B. this.formborderstyle = System.Windows.Forms.FormBorderStyle.FixedSingle; System.Drawing.Drawing2D.GraphicsPath path = new System.Drawing.Drawing2D.GraphicsPath(); path.addellipse(0, 0, this.width, this.height); Region reg = new Region(path); this.region = reg; C. this.formborderstyle = System.Windows.Forms.FormBorderStyle.None; System.Drawing.Drawing2D.GraphicsPath path = new System.Drawing.Drawing2D.GraphicsPath(); path.addellipse(0, 0, this.width, this.height); Region reg = new Region(path); this.region = reg; D. this.formborderstyle = System.Windows.Forms.FormBorderStyle.FixedSingle; System.Drawing.Drawing2D.GraphicsPath path = new System.Drawing.Drawing2D.GraphicsPath(); path.addellipse(0, 0, this.width, this.height); Region reg = new Region(); this.region = reg; 2 / 14

Answer: C 2.You are creating a Windows Forms application by using the.net Framework 3.5. The application requires a form to display a clock. You need to create a circular form to display the clock. Which code segment should you use? A. Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None Dim path As New System.Drawing.Drawing2D.GraphicsPath() path.addellipse(0, 0, Me.Width, Me.Height) Dim reg As New Region() Me.Region = reg B. Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle Dim path As New System.Drawing.Drawing2D.GraphicsPath() path.addellipse(0, 0, Me.Width, Me.Height) Dim reg As New Region(path) Me.Region = reg C. Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None Dim path As New System.Drawing.Drawing2D.GraphicsPath() path.addellipse(0, 0, Me.Width, Me.Height) Dim reg As New Region(path) Me.Region = reg D. Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle Dim path As New System.Drawing.Drawing2D.GraphicsPath() path.addellipse(0, 0, Me.Width, Me.Height) Dim reg As New Region() Me.Region = reg Answer: C 3 / 14

3.You are creating a Windows Forms application by using the.net Framework 3.5. You create a new form in the application. You add a ContextMenuStrip control named ctxmenu to the form. You have a user-defined class named CustomControl. You write the following code segment in the application. (Line numbers are included for reference only.) 01 CustomControl mycontrol = new CustomControl(); 02 You need to ensure that an instance of CustomControl is displayed on the form as a top-level item of the ctxmenu control. Which code segment should you add at line 02 A. ToolStripControlHost host = new ToolStripControlHost(myControl); ctxmenu.items.add(host); B. ToolStripPanel panel = new ToolStripPanel(); panel.controls.add(mycontrol); ctxmenu.controls.add(panel); C. ToolStripContentPanel panel = new ToolStripContentPanel(); panel.controls.add(mycontrol); ctxmenu.controls.add(panel); D. ToolStripMenuItem menuitem = new ToolStripMenuItem(); ToolStripControlHost host = new ToolStripControlHost(myControl); menuitem.dropdownitems.add(host); ctxmenu.items.add(menuitem); Answer: A 4.You are creating a Windows Forms application by using the.net Framework 3.5. You create a new form in your application. You add a PrintDocument control named pntdoc to the form. To support the print functionality, you write the following code segment in the application. (Line numbers are included for reference only.) 01 pntdoc.beginprint += new PrintEventHandler(PrintDoc_BeginPrint); 02... 4 / 14

03 bool canprint = CheckPrintAccessControl(); 04 if (!canprint) { 05 06 07 You need to ensure that the following requirements are met: When the user has no print access, font and file stream initializations are not executed and the print operation is cancelled. Print operations are logged whether or not the user has print access. What should you do? A. Add the following code segment at line 05. pntdoc.beginprint -= new PrintEventHandler(PrintDoc_BeginPrint); pntdoc.beginprint += new PrintEventHandler((obj, args) => args.cancel = true); pntdoc.beginprint += new PrintEventHandler((obj1, args1) => LogPrintOperation()); B. Add the following code segment at line 05. pntdoc.beginprint += new PrintEventHandler(delegate(object obj, PrintEventArgs args){); pntdoc.beginprint -= new PrintEventHandler(PrintDoc_BeginPrint); pntdoc.beginprint += new PrintEventHandler((obj1, args1) => LogPrintOperation()); C. Add the following code segment at line 05. pntdoc.beginprint -= new PrintEventHandler(PrintDoc_BeginPrint); pntdoc.beginprint -= new PrintEventHandler(delegate(object obj, PrintEventArgs args){); pntdoc.beginprint -= 5 / 14

new PrintEventHandler((obj1, args1) => LogPrintOperation()); D. Add the following code segment at line 05. pntdoc.beginprint -= new PrintEventHandler((obj, args) => args.cancel = true); pntdoc.beginprint += new PrintEventHandler(PrintDoc_BeginPrint); pntdoc.beginprint -= new PrintEventHandler((obj1, args1) => LogPrintOperation()); Answer: A 5.You are creating a Windows Forms application by using the.net Framework 3.5. You create a new form in your application. You add a PrintDocument control named pntdoc to the form. To support the print functionality, you write the following code segment in the application. (Line numbers are included for reference only.) 01 AddHandler pntdoc.beginprint, _ AddressOf PrintDoc_BeginPrint 02... 03 Dim canprint As Boolean = CheckPrintAccessControl() 04 If canprint = False Then 05 06 07 You need to ensure that the following requirements are met: When the user has no print access, font and file stream initializations are not executed and the print operation is cancelled. Print operations are logged whether or not the user has print access. What should you do? A. Add the following code segment at line 05. RemoveHandler pntdoc.beginprint, AddressOf PrintDoc_BeginPrint AddHandler pntdoc.beginprint, _ 6 / 14

Function(obj1, args1) args1.cancel = True AddHandler pntdoc.beginprint, AddressOf LogPrintOperation B. Add the following code segment at line 05. AddHandler pntdoc.beginprint, AddressOf EmptyEventHandler RemoveHandler pntdoc.beginprint, AddressOf PrintDoc_BeginPrint AddHandler pntdoc.beginprint, AddressOf LogPrintOperation C. Add the following code segment at line 05. RemoveHandler pntdoc.beginprint, AddressOf PrintDoc_BeginPrint RemoveHandler pntdoc.beginprint, AddressOf EmptyEventHandler RemoveHandler pntdoc.beginprint, AddressOf LogPrintOperation D. Add the following code segment at line 05. AddHandler pntdoc.beginprint, _ Function(obj1, args1) args1.cancel = True AddHandler pntdoc.beginprint, AddressOf PrintDoc_BeginPrint RemoveHandler pntdoc.beginprint, AddressOf LogPrintOperation Answer: A 6.You are creating a Windows Forms application by using the.net Framework 3.5. You plan to modify a list of orders within a DataGridView control in the application. You need to ensure that a value is required in the first column of the grid control. Which code segment should you use? A. private void datagridorders_cellvalidated( 7 / 14

object sender, DataGridViewCellEventArgs e) { if (e.columnindex == 0)? { var cellvalue = datagridorders[ e.columnindex, e.rowindex].value; if (cellvalue == null string.isnullorempty(cellvalue.tostring())) { datagridorders.endedit(); B. private void datagridorders_validated( object sender, EventArgs e) { if (datagridorders.currentcell.columnindex == 0) { var cellvalue = datagridorders.text;?if (cellvalue == null?string.isnullorempty(cellvalue.tostring())) {?datagridorders.endedit(); C. private void datagridorders_validating( object sender, CancelEventArgs e) { if (datagridorders.currentcell.columnindex == 0) { var cellvalue = datagridorders.text;?if (cellvalue == null string.isnullorempty(cellvalue.tostring()))?{ e.cancel = true; 8 / 14

? D. private void datagridorders_cellvalidating( object sender, DataGridViewCellValidatingEventArgs e) { if (e.columnindex == 0) { if (e.formattedvalue == null string.isnullorempty(e.formattedvalue.tostring()))?{ e.cancel = true;? Answer: D 7.You create a Windows application by using the.net Framework 3.5. The application is named APP1. APP1 has the following specifications: It merges information from text files. It reads each text file as a string. It runs on a server computer named Server1. Another application named APP2 also runs on Server1. You discover that when a function is used to merge the text files, APP1 consumes additional memory. This additional memory consumption affects the operations of APP2. You need to modify the design of APP1 to ensure minimum effect on APP2. What should you do? A. Use the + operator for the merge process. B. Use the StringBuilder.Append method for the merge process. C. Write a code segment to perform the merge process on a new thread. D. Write a code segment in a separate project to perform the merge process. Configure the project to start the merge operation as a new process. 9 / 14

Answer: B 8.You are creating a Windows Forms application by using the.net Framework 3.5. You plan to modify a list of orders within a DataGridView control in the application. You need to ensure that a value is required in the first column of the grid control. Which code segment should you use? A. Private Sub datagridorders_cellvalidated( _ ByVal sender As Object, _ ByVal e As DataGridViewCellEventArgs) _ Handles datagridorders.cellvalidated If e.columnindex = 0 Then Dim cellvalue = datagridorders(e.columnindex, e.rowindex).value If cellvalue = Nothing _ Or String.IsNullOrEmpty(cellValue.ToString()) Then datagridorders.endedit() End Sub B. Private Sub datagridorders_validated( _ ByVal sender As Object, _ ByVal e As EventArgs) _ Handles datagridorders.validated If datagridorders.currentcell.columnindex = 0 Then Dim cellvalue = datagridorders.text If cellvalue = Nothing Or _ String.IsNullOrEmpty(cellValue.ToString()) Then datagridorders.endedit() End Sub 10 / 14

C. Private Sub datagridorders_validating( _ ByVal sender As Object, _ ByVal e As CancelEventArgs) _ Handles datagridorders.validating If datagridorders.currentcell.columnindex = 0 Then Dim cellvalue = datagridorders.text If cellvalue = Nothing Or _ String.IsNullOrEmpty(cellValue.ToString()) Then e.cancel = True End Sub D. Private Sub datagridorders_cellvalidating( _ ByVal sender As Object, _ ByVal e As DataGridViewCellValidatingEventArgs) _ Handles datagridorders.cellvalidating If e.columnindex = 0 Then If e.formattedvalue = Nothing _ Or String.IsNullOrEmpty(e.FormattedValue.ToString()) Then e.cancel = True End Sub Answer: D 9.You are creating a Windows Forms application by using the.net Framework 3.5. You write the following code segment to bind a list of categories to a drop-down list. (Line numbers are included for reference only.) 01 OleDbConnection cnnnorthwind = new OleDbConnection(connectionString); 11 / 14

02 OleDbCommand cmdcategory = new OleDbCommand( "SELECT CategoryID, CategoryName FROM Categories ORDER BY CategoryName", cnnnorthwind); 03 OleDbDataAdapter dacategory = new OleDbDataAdapter(cmdCategory); 04 DataSet dscategory = new DataSet(); 05 dacategory.fill(dscategory); 06 You need to ensure that the drop-down list meets the following requirements: Displays all category names. Uses the category ID as the selected item value. Which code segment should you add at line 06? A. ddlcategory.datasource = dscategory; ddlcategory.displaymember = "CategoryName"; ddlcategory.valuemember = "CategoryID"; B. ddlcategory.datasource = dscategory.tables[0]; ddlcategory.displaymember = "CategoryName"; ddlcategory.valuemember = "CategoryID"; C. ddlcategory.databindings.add("displaymember", dscategory, "CategoryName"); ddlcategory.databindings.add("valuemember", dscategory, "CategoryID"); D. ddlcategory.databindings.add("displaymember", dscategory.tables[0], "CategoryName"); ddlcategory.databindings.add("valuemember", dscategory.tables[0], "CategoryID"); Answer: B 10.You are creating a Windows Forms application by using the.net Framework 3.5. You write the following code segment to update multiple databases on a SQL Server 2008 database. 12 / 14

(Line numbers are included for reference only.) 01 string connectionstringcustomer = @"Data Source=CUSTOMER;Integrated Security= SSPI;"; 02 string connectionstringorders = @"Data Source=ORDER ;Integrated Security= SSPI;"; 03 SqlCommand cmdcustomer = new SqlCommand(); 04 SqlCommand cmdorders = new SqlCommand(); 05 SqlConnection cnncustomer = new SqlConnection(connectionStringCustomer); 06 SqlConnection cnnorders = new SqlConnection(connectionStringOrders); 07 You need to ensure that all database updates are included in a single distributed transaction. Which code fragment should you add on Line 07? A. cnncustomer.open(); cnnorders.open();... cmdorders.executenonquery();... cmdcustomer.executenonquery(); cnnorders.close(); cnncustomer.close(); B. TransactionScope scope = new TransactionScope(); cnncustomer.open(); cnnorders.open();... cmdorders.executenonquery();... cmdcustomer.executenonquery(); cnnorders.close(); 13 / 14

cnncustomer.close(); scope.complete(); C. TransactionScope customerscope = new TransactionScope() { using (SqlConnection cnncustomer =?new SqlConnection (connectionstringcustomer)) { customerscope.complete(); using (TransactionScope ordersscope = new TransactionScope()) { using (SqlConnection cnnorders = new SqlConnection(connectionStringOrders)) { ordersscope.complete(); D. try { cmdorders.transaction = cnnorders.begintransaction();... cmdorders.executenonquery();... cmdcustomer.transaction = cnncustomer.begintransaction();... cmdcustomer.executenonquery(); cmdcustomer.transaction.commit(); cmdorders.transaction.commit(); catch { cmdcustomer.transaction.rollback(); cmdorders.transaction.rollback(); Answer: B 14 / 14