Exercises

  1. Open the solution file for the XML app that you just completed and do the following:

    • Go to the code for the Using XML Document button. If you do not have Dynamic Help on, click Help from the main menu and select Dynamic Help. Read the SDK file on the XmlDocument class to familiarize yourself with its capabilities.

    • Set a breakpoint on the Load method of the xDoc variable in the XPathSelectNodes click event. Step through the code and examine how the SelectNodes and SelectSingleNode methods behave compared to the XmlTextReader methods when retrieving node values.

    • Run the code for the DOMXmlAttribute click event. Using the Dynamic Help, familiarize yourself with the XmlAttribute, XmlNode, and XmlNodeList objects in the SDK.

    • Read about the differences of using the XmlReader classes versus the XmlDocument classes when working with XML files.

  2. Create a new ASP.NET Web Application. Using the databinding techniques you learned about over the last few days, do the following:

    • Add a ComboBox and DataGrid to the default WebForm1.aspx page.

    • Load the Customers.xml file into a DataSet, and then bind the DataSet to a DataGrid.

    • Load the ComboBox with the CustomerID field using an XmlReader, and add the CustomerID to the Items collection of the ComboBox.

    This will help you become familiar with using ASP.NET and loading XML files on Web pages.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.147.68.159