PrepAway - Latest Free Exam Questions & Answers

Category: 70-544

Exam 70-544: TS: Bing Maps Platform, Application Development

Which code fragment should you use?

You are creating a Web application by using the Virtual Earth 6.0 map control.

A Web page of the application provides links to a number of pre-defined locations. The application must meet the following requirements:

The links can be shared.
The links are encoded with map properties.
Users can copy the links to the Windows clipboard.

You need to write code to meet the requirements.

Which code fragment should you use?

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?

Which code segment should you insert at line 12?

You are creating a Virtual Earth 6.0 map. You use a page template that has a transparent header. You write the following HTML fragment to define the template.
01 <head>
02 <script type=”text/javascript”>
03 var map = null;
04 function GetMap(){
05 FormatMap();
06 map = new VEMap(‘Map’);
07 map.LoadMap();
08 }
09 function FormatMap(){
10 var mapEl = document.getElementById(‘Map’);
11 var headEl = document.getElementById(‘Header’);
12 …
13 }

14 </head>
15 <body onload=”GetMap();”>
16 <div id=’Header’ style=”position: relative; left: 5px; top:
5px; width:400px; height:100px; border: 2px solid black;”> 17 Header
18 </div>
19 <div id=’Map’></div>
20 </body>

You need to position the map so that the header is overlaid on the map and centered at the top.

Which code segment should you insert at line 12?

Which code segment should you use?

You are creating a browser-based Web application by using Virtual Earth 6.0 map control. A Web page of the application has a map and a list of locations.

When a user selects a location from the list, the application must meet the following requirements:

A default view of the selected location is loaded.
The selected location is centered.
The selected location appears in the three-dimensional mode, at an oblique pitch, and heads due north.

You need to program Virtual Earth map control to ensure that the requirements are met.

Which code segment should you use?

Which code segment should you insert at line 05?

You are creating an application that will display a Virtual Earth 6.0 map inside a pop-up window that will be viewed by using Microsoft Internet Explorer.

You write the following code segment.

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

You need to ensure that the following requirements are met:

The height of the map is half the height of the pop-up window. The width of the map is one-third the width of the pop-up window.

Which code segment should you insert at line 05?

var pos=location.search.indexOf("?

You are creating a Web application. You are given the URL of a Web page. When the URL is encoded with map control properties, it generates custom maps by using the Virtual Earth 6.0 map control.

The Web page uses the following JavaScript code segment to decode the URL.

var pos=location.search.indexOf(“?”) +1;
var loc1=location.search.substr(pos);
var point1=loc1.split(” & “);
var a= point1[0];
var b= point1[1];
var c= point1[2];
var d=point1[3];
var e= point1[4];
var f= point1[5];
var g= point1[6];
map=new VEMap(‘myMap’);
map.LoadMap(new VELatLong(a,b),c,d,e,f,g);

You need to encode the URL to generate a custom map by using your own settings.

Which encoded URL should you use?


Page 9 of 9« First...56789