V11 Displaying Driving Directions on a Map Control and Adding a Marker to the Map Part 1

Uploaded on Aug 16, 2013 / 132 views / 226 impressions / 0 comments

alpha01803

More from this user

Description

FP11_DLGMAP2 Alpha Five v11 Dialog component map driving directions

When you place a map control on a Dialog, you can call any of the various methods that the map object exposes.There are quite a few different methods exposed by the map object. In these videos, we show how the .plotRoute() method can be used to display a route and driving directions for a starting and ending address. Next, we show how the .addMarker() method can be used to add a marker to the map. Important: In the videos, we show that the map object's .viewMarkers() method is called after the .addMarker() method is called. Actually, the .viewMarkers() method should be called in the "onAddComplete" callback event. This ensures that no attempt is made to show the marker before it has actually been placed on the map. The "onAddComplete" event in the settings object should be defined as follows: onAddComplete: function(markerSettings markerObject){ this.viewMarkers("m1"); } Note also, in the onAddComplete event function we can use "his" to reference the map object.

Tags

  • ftp
  • Five
  • Alpha
  • v11