3.1. Understanding the MapPoint 2004 Data APIIn MapPoint 2004, both business data and demographic data are represented using the DataSet class. An active Map object exposes the DataSets collection, which you use to access a valid DataSet object. How does a DataSets collection get its data wrapped as a DataSet object? The DataSets collection is different from traditional .NET collectionsit not only exposes a collection of DataSet objects, but it also offers methods to import external data and to access MapPoint 2004 demographic data. A DataSet object is similar to a data table with rows and columns and regular querying capabilities. However, a DataSet object allows you to query the records or data rows based on location information. Each query results in a Recordset object containing the records that satisfy the location-based query. The DataSet object can also be used to display data on maps. In essence, if you are using any data features (such as data maps, territories, etc.) in MapPoint 2004 APIs, the DataSet class is the root for all these tasks; Figure 3-1 shows the relationships between an active Map object, a DataSets collection, a DataSet object, and a Recordset object. Figure 3-1. MapPoint 2004 data-related API object model
Tables 3-1 and 3-2 show some of the key methods exposed on the DataSet and RecordSet objects.
With this introduction, let's look at specifics of dealing with visualization of data using MapPoint 2004. |