Prepare

Land Desktop Map 3D Samples

 
Prepare
 
 
 

The Prepare method does the following:

  1. Uses the CreateFeatureSourceDefinition utility method to create the XML data for connecting to a MySql feature source given a set of connection settings hard-coded within the Prepare method source.
  2. Uses the GetNewResourceId function to generate a resource Id value that is not currently used.
  3. Passes the resource Id to the TestConnection method of the FeatureService object. If the connection does not work, an error message is printed and Prepare exits.
  4. Calls the utility method AddAllToMap to add all the features in the MySql feature source to the document.