Documente Academic
Documente Profesional
Documente Cultură
- The delegate for this event specifies an instance of the UserPreferenceChangedEventArgs class, which contains a Category property that specifies the type of preference change that occurred
Read, write, and validate XML by using the XmlReader class and the XmlWriter class
When reading large amounts of XML data, you should use the XmlReader class for efficiency - This class represents a forward-only, read-only cursor for XML data The XmlReader class is efficient because the entire XML document does not need to be loaded into memory for processing - One drawback of using the XmlReader class is that once you read a particular node, you can no longer access its ancestors or previous siblings You can use the XmlReader class to validate XML data by passing an instance of XmlReaderSettings to the XmlReader constructor The XmlReaderSettings class contains a ValidationType property that specifies the type of validation, if any, to be performed when the XML data is read - The ValidationType property supports three values: DTD, Schema, and None
The PrintPreviewDialog class represents the standard Print Preview dialog box that should be familiar to Windows users - It allows you to preview documents to determine how the printed copies will look The PageSettings class contains properties that allow you to change the paper size, orientation, and margins The PaperSize property allows you to set the paper size The Landscape property allows you to specify whether the orientation should be landscape or portrait The Margins property allows you to set the page margins
Enhancing Usability
Perform drag-and-drop operations
The ItemDrag event of the TreeView control is raised when a user begins to drag a node in the TreeView control The Data property of the DragEventArgs class is an instance of IDataObject, which provides methods for transferring data either from the Clipboard or between components in drag-and-drop operations - You must call the GetData method of the IDataObject interface to obtain the data to be dropped - This method accepts a data format that indicates the type of data that is returned The DragOver event is raised as the mouse cursor moves over a control during a drag-and-drop operation
Create a custom Windows Forms control by inheriting from the control class
Only controls that derive from Control can be displayed on forms The OnPaint method is called whenever regions of a control are invalidated
When an application is started from a Web server, it is downloaded and installed to a temporary location - The files are deleted when the application is closed If you create a ClickOnce deployment that installs an application, the files will remain on the computer after the application is closed If a WPF application loads modules dynamically, those modules must be referenced in an application manifest so that it can find the modules at runtime
Install a Visual Studio Tools for Office (VSTO) application by using ClickOnce
Visual Studio Tools for Office system 3.0 Runtime is the runtime required by Office 2007 add-ins and document applications
Configure and work with Windows Vista User Account Control (UAC) by using ClickOnce deployments
The Standard User Analyzer is a tool that can be downloaded from the Microsoft Web site - It is used to analyze an existing application to identify problems that will occur when an application is run under a standard user account
You can create a Windows Installer file that targets a specific processor platform by creating a deployment project and setting the TargetPlatform property
Acronyms
Acronym CLR DOM GAC MDI UI WPF Definition Common language runtime Document Object Model Global assembly cache Multiple-document interface User interface Windows Presentation Foundation