Facilities Management Application Example Code (continued)
xyPt.setY(xyPt.getY() + delta)
}
if (direction == 'Ur') {
xyPt.setX(xyPt.getX() + delta)
xyPt.setY(xyPt.getY() + delta)
}
if (direction == 'Down') {
xyPt.setY(xyPt.getY() - delta)
}
if (direction == 'Ld') {
xyPt.setX(xyPt.getX() - delta)
xyPt.setY(xyPt.getY() - delta)
}
if (direction == 'Rd') {
xyPt.setX(xyPt.getX() + delta)
xyPt.setY(xyPt.getY() - delta)
}
// Zoom to the new location
myScale = map.getScale();
map.zoomScale(xyPt.getY(), xyPt.getX(), myScale);
map.setAutoRefresh(true);
map.refresh();
}//ends panning
}
// =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= //
// Function:
GoToOrig(lat, lon)
// Description:
Arguments:
lat, lon
// Returns: nothing
// =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= //
function GoToOrig(lat, lon){
var map = getMap();
map.zoomWidth(lat, lon, 400, "FT");
}
// =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= //
// Function:
reportsDlg()
// Description:
// Arguments:
none
// Return:
none
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*/
function reportsDlg(){
var map = getMap();
var sel = map.getSelection();
var mapLayer = map.getMapLayer("Offices");
if ((sel.getNumObjects() < 1) || (mapLayer.isVisible() == false)){
alert("You must select an office first.");
}
else{
Zooms to the lat lon specified with a width of 400 ft
shows the reports dialog for generating reports
+
+
Facility Management Application
//
+
+
|
159
Need help?
Do you have a question about the 15606-011408-9330 - MAPGUIDE R6.3 SITE LIC-UPG R6 and is the answer not in the manual?