Autodesk 15606-011408-9300 Developer Guide - Page 146
Incident Entry & Reporting
UPC - 606121429548
View all Autodesk 15606-011408-9300 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 146 highlights
Municipal Application Example Code (continued) // instead, display alert else alert("The Autodesk MapGuide Viewer is busy. Please try again in a few seconds."); } Function: digit() // Description: Lets users create report data for a specified // point. (called by the 'Digitize Incident' button, under // 'Incident Entry & Reporting') // // NOTE: This function just gathers the point coordinates, // fires the onDigitizedPoint event, and passes the coordinates // to that event. The event is linked to a function (defined // in a separate frame -- see www.autodesk.com/mapguidedemo for // the source) that runs a ColdFusion file and creates a new // window to hold the ColdFusion-generated HTML output. The HTML // output includes a form that lets enter text and add that text // to the map as point data. // // Arguments: none // Returns: nothing function digit() { // Use browserId variable (defined at beginning of script) // to determine if user has Netscape or Internet Explorer; // doesn't bother to call getMap(), because entire function // varies by browser // If Netscape... if (browserId == 1) { // Get instance of MGMap, assign to map variable map = parent.main.document.embeds[0]; // If Autodesk MapGuide Viewer is not busy, call digitizePoint() method; // otherwise display alert (because digitizePoint() fires // the onDigitizedPoint event, we must pass the observer // as a function argument) if (map.isBusy() == false) map.digitizePoint(parent.rightempty.document.obs); else alert("The Autodesk MapGuide Viewer is busy. Please try again in a few seconds."); } // If Internet Explorer... if (browserId == 2) 146 | Chapter 7 Applications