Demonstration Examining Data Set Structure

illegal for non-trainer use

Introduction illegal for non-trainer use

In this demonstration, you will load an XSD schema into a DataSet. You will then use DataSet properties and methods to retrieve information about the tables in the DataSet. (code Walk thru).

1. Open PersonPet.xsd and explain how the XSD tags are mapped to relational objects in the DataSet.

2. Open the ExistingSchema solution file with Visual Studio.

3. Double-click the Get Schema button and show the code.

4. Point out that the ParseSchema procedure loads the DataSet myDS with schema information from PersonPet.xsd.

5. Explain the code in the Button1_click procedure. Point out that Tables, Columns, ColumnName, and Count properties are used to return information about the number of tables and the columns in each table.

6. Point out that a set of nested loops is used to reference each column in each table.

7. Run the application and observe the results.

8. Quit Visual Studio.

0 0

Post a comment