Mar 2016 updated: Exambible Microsoft 70-526 exam cram 1-15

Exam Code: 70-526 (Practice Exam Latest Test Questions VCE PDF)
Exam Name: Microsoft .NET Framework 2.0 - Windows-based Client Development is in development
Certification Provider: Microsoft
Free Today! Guaranteed Training- Pass 70-526 Exam.

2016 Mar 70-526 Study Guide Questions:

Q1. You are creating a Windows Forms application. You want to execute a method named ProcessAmount in the background of the application. The method you want to execute requires that an integer value of 13 is passed.  You need to pass an integer value of 13 to a starting background thread.  Which two code segments should you use? (Each correct answer presents part of the solution. Choose two.)

A. ThreadStart ts = new ThreadStart(ProcessAmount);

Thread t = new Thread(ts, 13);

B. ParameterizedThreadStart ts = new ParameterizedThreadStart(ProcessAmount);

Thread t = new Thread(ts);

C. t.Start();

D. t.Start(13);

Answer: BD


Q2. You are building a custom extended button control. This control handles its own painting by displaying a particular metric value in the upper right corner of the button, as shown in the exhibit. (Click the Exhibit button.)  You test this feature and verify that it works correctly. You also want the displayed value to be updated in real time as the user uses the application. You override the OnPaint method of the control to raise the Paint event when required. Your project compiles and builds with no problems, but the control does not paint itself correctly. You need to ensure that the control paints itself correctly. What should you do?


A. Call the base OnPaint method of the class from within your OnPaint method.

B. Raise the Paint event handler from within the OnPaint method.

C. Call the OnPaint method of the base class from within the Paint event.

D. Use the DefaultEvent attribute on your control class to specify that events will correctly ripple down the event chain from the base class to your current instance.

Answer: A


Q3. You are creating a multiple-document interface (MDI) Windows Forms application that contains an MDI parent form and an MDI child form. You add a MenuStrip control to the parent form and a MenuStrip control to the child form. You add a top-level menu item labeled File to each menu. You then add different submenu items to each menu.  When a child window is visible, the application should display a single top-level File menu that contains the combined set of submenu items.

You need to set form properties so that the menus combine correctly. What should you do?

A. Set the MergeAction property of the child forms File menu item to MatchOnly. Set the MergeAction property of the child forms submenu items to Insert.

B. Set the MergeAction property of the parent forms File menu item to MatchOnly. Set the MergeAction property of the parent forms submenu items to Insert.

C. Set the MergeAction property of the child forms File menu item to Insert. Set the MergeAction property of the child forms submenu items to MatchOnly.

D. Set the MergeAction property of the parent forms File menu item to Insert. Set the MergeAction property of the parent forms submenu items to MatchOnly.

Answer: A


Q4. You are creating a Windows Forms application. You create a class named ApplicationUtilities and add a method named BackgroundProcess. You anticipate that the BackgroundProcess method may require several minutes or longer to execute. You need to ensure that the application remains responsive while the BackgroundProcess method runs. Which two actions should you perform? (Each correct answer presents part of the solution. Choose two.)

A. Create an instance of a System.Threading.ThreadStart delegate named AsyncDelegate, and pass the BackgroundProcess method in as a parameter.

B. Create a delegate named AsyncDelegate that matches the signature of the BackgroundProcess method.

C. Implement the IAsyncResult interface for the ApplicationUtilities class.

D. Override the BeginInvoke and EndInvoke methods for the ApplicationUtilities class.

E. Call AsyncDelegate.BeginInvoke to execute the method. After the method is complete, call AsyncDelegate.EndInvoke.

F. Call ApplicationUtilities.BeginInvoke to execute the method. After the method is complete, call ApplicationUtilities.EndInvoke.

Answer: BE


Q5. You are creating a Windows Form that includes printing functionality to print an image of the form. A helper function with the following signature creates a bitmap of the current form.

private Bitmap CreateFormImageBitmap(Graphics graphic)

You need to implement the PrintPage event handler to call the helper function and draw the image onto the print document. Which code segment should you use?

A. Graphics g = e.Graphics;

Bitmap formImageBitmap = CreateFormImageBitmap(g);

e.Graphics.DrawImage(formImageBitmap, e.MarginBounds);

B. Graphics g = this.CreateGraphics();

Bitmap formImageBitmap = CreateFormImageBitmap(g);

g.DrawImage(formImageBitmap, g.ClipBounds);

g.Dispose();

C. Graphics g = this.CreateGraphics();

Bitmap formImageBitmap = CreateFormImageBitmap(e.Graphics);

g.DrawImage(formImageBitmap, g.ClipBounds);

g.Dispose();

D. Graphics g = this.CreateGraphics();

Bitmap formImageBitmap = CreateFormImageBitmap(g);

e.Graphics.DrawImage(formImageBitmap, e.MarginBounds);

g.Dispose();

Answer: D


70-526 test question

Rebirth 70-526 dumps:

Q6. You are working with a Windows Forms application that uses the Application Settings features to persist user settings between run-time sessions. You need to perform certain processing actions when user settings are changed at run time. Which two events should you handle to achieve this goal? (Each correct answer presents part of the solution. Choose two.)

A. SettingChanging

B. PropertyChanged

C. StateChange

D. SettingsLoaded

E. Change

Answer: AB


Q7. You are creating a complex data-entry Windows Forms application. The application allows users to move text between text boxes by using drag-and-drop operations. Your company also has other data-entry applications. You need to ensure that users can perform similar drag-and-drop operations between the different applications. What should you do?

A. Ensure that the AllowedEffect property in each application includes the DragDropEffects.Link setting.

B. Ensure that the Effect property in each application includes the DragDropEffects.Link setting.

C. Ensure that the Effect property in the drag source application includes the DragDropEffect.Link setting, and the AllowedEffect property in the drop target application is set to DragDropEffect.Copy.

D. Ensure that the Effect and AllowedEffect properties in each application include the DragDropEffect.Copy setting.

Answer: D


Q8. You are creating a shaped Windows Form. The shape and background for the form are available in a bitmap file named Background.bmp. The FormBorderStyle property is set to None and the BackgroundImage property is set to background.bmp. However, when the application runs, the entire image including all of the background is visible and the form still appears to be rectangular. You need to configure the form so that it takes the shape of the bitmap file without the background. What should you do?

A. Set the BackgroundImageLayout property to None.

B. Set the BackColor property of the form to the background color of Background.bmp.

C. Set the Opacity property of the form to 0%.

D. Set the TransparencyKey property of the form to the background color of Background.bmp.

Answer: D


Q9. You need to create a Windows Forms application that uses a nonrectangular form as its user interface. What should you do?

A. Set the FormBorderStyle property of the form to None. Set the BackgroundImage property of the form to a bitmap file that represents the shape you want the form to take. Set the TransparencyKey property to the background color of the bitmap file.

B. Set the FormBorderStyle property of the form to None. Set the BackgroundImage property of the form to a bitmap file that represents the shape you want the form to take. Set the TransparencyKey property to Transparent.

C. Set the FormBorderStyle and BackgroundImageLayout properties to None. Set the BackgroundImage property of the form to a bitmap file that represents the shape you want the form to take. Set the TransparencyKey property to Transparent.

D. Set the FormBorderStyle property to None and the BackColor property to Control. Set the BackgroundImage property of the form to a bitmap file that represents the shape you want the form to take. Set the TransparencyKey property to Transparent.

Answer: A


Q10. A method in your Windows Forms application executes a stored procedure in a Microsoft SQL Server 2005 database, and then executes a second stored procedure in a second SQL Server 2005 database. You need to ensure that the call to the first stored procedure writes changes only if the call to the second stored procedure succeeds. Installation requirements prohibit you from introducing new components that use the COM+ hosting model. What should you do?

A. Implement a transactional serviced component. Add methods to this component to encapsulate the connect operation and execution of each stored procedure. Register and use this serviced component.

B. Add a TransactionScope block. Connect to each database and execute each stored procedure within the TransactionScope block. Call the TransactionScope.Complete method if the call to both stored procedure succeeds.

C. Connect to both databases. Call the SqlConnection.BeginTransaction method for each connection. Call the SqlTransaction.Commit method on both returned transactions only if both stored procedures succeed.

D. Add a try-catch-finally block. Connect to each database and execute each stored procedure in the try block.

Answer: B


70-526 exam

Download 70-526 pdf exam:

Q11. A Windows Forms application reads the following XML file.

<?xml version="1.0"?>

 <x:catalog xmlns:x="urn:books">

   <book id="bk101">

     <author>Gambardella, Matthew</author>

     <title>XML Developer's Guide</title>

   </book>

   <book id="bk102">

     <author>Ralls, Kim</author>

     <title>Midnight Rain</title>

   </book>

</x:catalog>

The form initialization loads this file into an XmlDocument object named docBooks. You need to populate a ListBox control named lstBooks with the concatenated book ID and title of each book. Which code segment should you use?

A. XmlNodeList elements = docBooks.GetElementsByTagName("book");

foreach (XmlElement node in elements) {

   string s = node.GetAttribute("id") + " - ";

   s += node.SelectSingleNode("title").InnerText;

   lstBooks.Items.Add(s); 

}

B. XmlNodeList elements = docBooks.GetElementsByTagName("book"); 

foreach (XmlElement node in elements) {

   string s = node.SelectSingleNode("id") + " - ";

   s += node.GetAttribute("title");

   lstBooks.Items.Add(s); 

}

C. XmlNodeList elements = docBooks.GetElementsByTagName("book"); 

foreach (XmlElement node in elements) {

   string s = node.GetAttribute("id") + " - ";

   s += node.SelectSingleNode("title").Value;

   lstBooks.Items.Add(s); 

}

D. XmlNodeList elements = docBooks.GetElementsByTagName("book");

foreach (XmlElement node in elements) {

   lstBooks.Items.Add(node.InnerXml); 

}

Answer: A


Q12. You are customizing a Windows Form. You want to display a custom icon for your composite control named DialerControl in the toolbox. You need to customize the toolbox icon. You want to achieve this goal by using the minimum amount of effort.  Which action or actions should you perform? (Choose all that apply.)

A. Add a bitmap named DialerControl.bmp to the user control project.

B. Change the build action of the bitmap to Embedded Resource.

C. Add a ToolboxBitmap attribute to the DialerControl class, passing in DialerControl.bmp as a parameter.

D. Add a ToolboxBitmap attribute to the DialerControl class, passing in typeof(DialerControl) as a parameter.

Answer: AB


Q13. You are creating a Windows Form that contains several ToolStrip controls. You need to add functionality that allows a user to drag any ToolStrip control from one edge of the form to another.  What should you do?

A. Configure a ToolStripContainer control to fill the form. Add the ToolStrip controls to the ToolStripContainer control.

B. Configure a Panel control to fill the form. Set the Anchor properties of the ToolStrip controls to Top, Bottom, Left, Right.

C. Add the ToolStrip controls to another ToolStrip control that is hosted by a ToolStripControlHost control.

D. Add the ToolStrip controls to the form. Set the Anchor properties of the ToolStrip controls to Top, Bottom, Left, Right.Set the FormBorderStyle property of the form to SizableToolWindow.

Answer: A


Q14. You are customizing a Windows Form. The form includes a menu that has several ToolStripMenuItem controls. An event handler is configured to handle the Click event for all ToolStripMenuItem controls. The event handler has the following signature.

private void mnu_Click(object sender, EventArgs e)

The form class includes a method that has the following signature.

private void LogClick(string ctlName)

You need to add code so that when a user clicks a ToolStripMenuItem control, the mnu_Click method calls the LogClick method. The LogClick method must be called with the ctlName parameter set to the menu text in the ToolStripMenuItem control. Which code segment should you use?

A. ToolStripMenuItem mnuItem = (ToolStripMenuItem) sender;

LogClick(mnuItem.Text);

B. LogClick(e.ToString());

C. LogClick(this.Text);

D. ToolStripMenuItem mnuItem = (ToolStripMenuItem) this.GetContainerControl();

LogClick(mnuItem.Text);

Answer: A


Q15. You are creating a Windows Form. You add a TableLayoutPanel control named pnlLayout to the form. You set the properties of pnlLayout so that it will resize with the form. You need to create a three-column layout that has fixed left and right columns. The fixed columns must each remain 50 pixels wide when the form is resized. The middle column must fill the remainder of the form width when the form is resized. You add the three columns in the designer. Which code segment should you use to format the columns at run time?

A. pnlLayout.ColumnStyles.Clear();

pnlLayout.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 50F));

pnlLayout.ColumnStyles.Add(new ColumnStyle(SizeType.AutoSize, 100F));

pnlLayout.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute,  50F));

B. pnlLayout.ColumnStyles[0].Width = 50F;

pnlLayout.ColumnStyles[0].SizeType = SizeType.Absolute;

pnlLayout.ColumnStyles[2].Width = 50F;

pnlLayout.ColumnStyles[2].SizeType = SizeType.Absolute;

C. pnlLayout.ColumnStyles[0].Width = 50F;

pnlLayout.ColumnStyles[0].SizeType = SizeType.Absolute;

pnlLayout.ColumnStyles[1].Width = 100F;

pnlLayout.ColumnStyles[1].SizeType = SizeType.AutoSize;

pnlLayout.ColumnStyles[2].Width = 50F;

pnlLayout.ColumnStyles[2].SizeType = SizeType.Absolute;

D. pnlLayout.ColumnStyles.Clear();

pnlLayout.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 50F));

pnlLayout.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F));

pnlLayout.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 50F));

Answer: D



see more 70-526 - Microsoft .NET Framework 2.0 - Windows-based Client Development is in development

Microsoft 70-526 Certification Sample Questions and Answers: https://www.braindumpsall.net/70-526-dumps/

P.S. New 70-526 dumps PDF: http://www.4easydumps.com/70-526-dumps-download.html