POST
|
I'm trying re-create this action allowing the selected highlight symbology to remain after the pop up is closed in the most recent version of web appbuilder (2.23). The code has been changed to the point that Robert's solution is no longer valid. For example, there is not a 'show, hide' action in the current Widget.js file. I did have it functioning in an older version of web appbuilder (2.4). Any insight on where this action can now be made? And on a similar topic, how can this symbolgy also remain when typical pop up is closed that was not executed from the Search widget? Thanks.
... View more
03-21-2022
09:22 AM
|
0
|
0
|
680
|
POST
|
I'm wondering if there is a way to disable the "segment length" when you are measuring area, so it doesn't give those odd results.
... View more
03-15-2016
11:20 AM
|
0
|
1
|
173
|
POST
|
Thanks Tom. That seems to work exactly how I was hoping. I agree that it would be nice for them to have a click event built back into the dijit.
... View more
03-15-2016
09:19 AM
|
0
|
1
|
1090
|
POST
|
Thanks for the ideas Tom. I was working with them and am still having problems. Anytime I remove the "measure" event, the script no longer knows what do when in the midst of the active measuring. What I'm trying to do is add a segment length shown each time a user clicks, while still showing the total length of all segments at "measure-end". I guess what I need is a way for it to know to measure but not to send any values until the map is clicked instead of sending values constantly as the mouse moves (basically overriding the new functionality of v3.16). Below is the code section that was functioning in version 3.15: var segmentLength = 0; //used in measure tool to track last segment length var PrevM = 0; //used in measure tool to track last total measurement var Mtype = ''; //used to track measurement units for display var measurement = new Measurement({ map: map, defaultAreaUnit: Units.ACRES, defaultLengthUnit: Units.FEET, }, dom.byId("measurementDiv")); measurement.startup(); measurement.on("measure-start", function (evt) { segmentLength = 0; PrevM = 0; dom.byId('spanSegment').innerHTML = 'Segment Length: ' + segmentLength.toFixed(1) + ' ' + Mtype; }); measurement.on("measure", function (evt) { var myVal = evt.values; //total measurement value segmentLength = myVal - PrevM; //new segment value PrevM = myVal; //remember current total measurement for next click dom.byId('spanSegment').innerHTML = 'Segment Length: ' + segmentLength.toFixed(1) + ' ' + Mtype; }); measurement.on("measure-end", function (evt) { var myVal = evt.values; segmentLength = myVal - PrevM; dom.byId('spanSegment').innerHTML = 'Segment Length: ' + segmentLength.toFixed(1) + ' ' + Mtype; segmentLength = 0; PrevM = 0 }); measurement.on("tool-change", function (evt) { dom.byId('spanSegment').innerHTML = ''; //zero out current values Mtype = evt.unitName; }); measurement.on("unit-change", function (evt) { Mtype = evt.unitName; });
... View more
03-15-2016
07:07 AM
|
0
|
4
|
1090
|
POST
|
In version 3.15, I have a working measure event to fire a measurement each time the user single-clicks while using the tool. With the change to 3.16, this event now fires when the mouse is moved, which causes problems with the way we are measuring. Does anyone know what event to call in the updated version for each time the map is single clicked while using the tool?
... View more
03-14-2016
01:04 PM
|
2
|
11
|
2774
|
Title | Kudos | Posted |
---|---|---|
2 | 03-14-2016 01:04 PM |
Online Status |
Offline
|
Date Last Visited |
03-24-2022
05:21 AM
|