Which code segment should you insert at line 06?

You are creating a Virtual Earth 6.0 application. The application allows users to enter an address and view the corresponding mapped location. A Print Preview link appears next to the location. The link opens a pop-up window that contains the location information in a query string.

The map load in the pop-up window is defined by the following code segment. (Line numbers are included for reference only.)

01 var loc = … ;
02 var map = null;
03 function GetMap(){
04 map = new VEMap(‘PrintPreviewMap’);
05 map.LoadMap();
06 …
07 }

The variable named loc in the code segment is an object that contains the id, address, latitude, longitude, and zoom properties that are present in the query string.

You need to ensure that the pop-up window meets the following requirements:

It uses the properties in the query string to display the location.
It does not display map controls.

Which code segment should you insert at line 06?

You are creating a Virtual Earth 6.0 application. The application allows users to enter an address and view the corresponding mapped location. A Print Preview link appears next to the location. The link opens a pop-up window that contains the location information in a query string.

The map load in the pop-up window is defined by the following code segment. (Line numbers are included for reference only.)

01 var loc = … ;
02 var map = null;
03 function GetMap(){
04 map = new VEMap(‘PrintPreviewMap’);
05 map.LoadMap();
06 …
07 }

The variable named loc in the code segment is an object that contains the id, address, latitude, longitude, and zoom properties that are present in the query string.

You need to ensure that the pop-up window meets the following requirements:

It uses the properties in the query string to display the location.
It does not display map controls.

Which code segment should you insert at line 06?

A.
map.PanToLatLong(new VELatLong(loc.latitude, loc.longitude)); map.AddPushpin(map.GetCenter()); map.SetZoom(loc.zoom); map.HideDashboard();

B.
map.PanToLatLong(new VELatLong(loc.latitude, loc.longitude)); map.AddShape(new VEShape(VEShapeType.Pushpin, new VELatLong(loc.latitude, loc.longitude))); document.getElementById(map_dashboard).style.display = “none”;

C.
map.FindLocation(loc.address); map.AddShape(new VEShape(VEShapeType.Pushpin, new VELatLong(loc.latitude, loc.longitude))); document.getElementById(‘map_dashboard’).style.display = “none”;

D.
map.SetCenterAndZoom(new VELatLong(loc.latitude, loc.longitude), loc.zoom); map.AddShape(new VEShape(VEShapeType.Pushpin, new VELatLong(loc.latitude, loc.longitude))); map.HideDashboard();



Leave a Reply 0

Your email address will not be published. Required fields are marked *