Is there a widget in Web App Builder to allow you to set a fixed scale at which a map appears? Ideally you could enter the scale, but if not a pick list would do?
Ta
Simon
Anyone got a widget for this one yet? My basemaps are not cached, either vector tiles or dynamic map services which dont have fixed LODs.
I would note, that if ArcGIS Server resampled on the fly (like it always should have) one thing, it would save every customer in the world with aerials dozens of terabytes of disk space. Really. I cache to 1:70 because resampling:true in the REST API as a flag, doesn't work. (allegedly that bug was fixed in 10.7.1, I have yet to tested yet but will be soon. Change default behavior to resampling: "true" for tiled services Change default behavior to resampling: "true" for tiled services ) but then.. this would be a non-issue. Tiles and imagery could be bilinear resampled on the fly. Meantime, tile on demand I would like to also work hand in hand. Let's say people zoom to 70 and I have not cached that, but I did set the LOD for that in a custom tile scheme. My idea... First... the resample loads. Then... the better quality tile loads after 30 secs from tile on demand, and from there on out is already tiled. So customers aren't waiting on tile on demand. Also... resampling would enable going to arbitrary scales in between LODs. Basically, I understand some of the platform constraints as currently designed. And hence the platform needs feature enhancements to support resampling of tiled imagery at any arbitrary scale. So it "just works". Engineers and the like are used to being able to just view something at a particular scale.
I would highly recommend this feature enhancement as it would free up enormous space on customer SANs (no more caching to 1:70) in addition to making more inroads in engineering circles. (i.e.. revenue...)
Our users for a site I am creating have already noted this. And lack of labeling what the different systems are. For example, I added DMS, decimal degrees and MGRS. https://cloud.sagis.org/sagisnext2 Sure I could inject it but... WAB team could make the coordinate options label what they are. I'll wait a few quarters and see if they do. For example if it's GA State Plane East in MGRS, that is exactly what the text should say in the HTML/DOM for the selection. Otherwise it's trial and error. Same for not having the coordinates update in real time, is it would be a nice touch.
Struggling with this myself. But I'm using WAB in a Portal environment in a large organisation, so it's not so easy for me as simply "Adding a Widget". It does seem a bit silly that if you customise your own scales using WAB you should be able to view the scales you've specified.
Kevin,
In the past this would require a round trip to the GeometryService to re-project the cursor coordinates and every mouse move would require this round trip which is NOT practical at all and makes a very "Chatty" application. In today's JS API where is the projection class that allows for clientside projection in modern browsers so this could be more of an option but no one has gone down the road of make a widget or updating the coordinate widget to use the projection class.
Oh yes that is what I meant, they were loaded as dynamic 'map image' layers. And remarkably degraded the dynamic raster looked in comparison the tiled one. Sorry I should indeed have written more clearly - I mean the coordinates can't they be re-projected in real time? Wouldn't seem like that heavy of a lift as a calculation? But I am just guessing there on that. And it's germane because I offer state plane (in dec. degrees and DMS) as well as 3857 to display coordinates in my viewer. I mention all this because I wish the coordinates would also update their display in real time as the cursor moves when in state plane and not just 3857.
While basemaps have defined LODs with the Esri/Google/Bing system can't they reproject on the fly from the esri server?
No. A basemap is a cached layer and cached means that there are tiles that are in a certain projection based at certain scales, that are generated before hand. There is nothing dynamic about a cached basemap (i.e. nothing can be changed at runtime). If you choose to add the layer as an ArcGISDynamicMapServiceLayer instead of ArcGISTiledMapServiceLayer to a basemap layer then yes you can re-project on the fly but you loose all the advantages of ArcGISTiledMapServiceLayer caches.
While basemaps have defined LODs with the Esri/Google/Bing system can't they reproject on the fly from the esri server? I did that years ago with a custom JS API app. Although I do remember they looked a little uglier, I think when it reprojected back then, it spit out as a jpeg with low compression. I don't mean the fact that it would resample, which it would do of course to fit the new projection, but I could also tell there were also jpeg artifacts. Nevertheless ability to define absolute scale would be very useful. If it is a map app used for field measurement then having nice, even scales to make maps to measure in the field off of is useful to engineers and other folks. Just a thought. And even before they implement that just showing the absolute scale text, and a note like 1"=100' or 1 inch = 100 feet (US) would be nice to add the WAB scalebar widget. Interesting the coordinates could not reproject in real time that would not seem like too much computation but maybe I'm wrong. I had also noticed that and wished it worked in real time for state plane (my app is 3857 of course, due to my previous experience with compressed basemap tiles); so I project my vector data to 3857 for loading speed.
Simon,
The coordinate widget will only give a running display if the basemap is in Web mercator (102100) or geographic (4326) spatial references.
Hi folks,
Thanks for all your help. This could technically be seen as a separate question, but since you all seem very knowledgeable in this area I thought I'd ask. The "co-ordinates" widget doesn't seem to be working in so far as there is no running display. I can click on the widget and it will then add a marker for which it gives me the co-ordinates, but I'm used to it just giving a running display as you move the mouse around.
Any ideas why this should be?
Thanks Rich. I'm pretty sure I'll have to talk to someone in the main GIS team to work out just what I'm doing, but I'm sure they'll understand this.
Here Ya go!
Add this widget to your project.
Hi Rich,
So how did you get the scale to appear, as that in itself would be useful? I know how to add a scale bar, but not to display the scale.
The base map is the issue...
Create your own base map with the correct WKID.
Post this base map to your ArcGIS online account, this is now your "itemId:"
Create your scale lodes in the Config. Each click of the mouse moves to a defined LOD
Example:
Thanks for the clarification. I've been speaking to a colleague who thinks that we use a bespoke map base, so might be able to control it. I'll look into this further and, if it is possible, will come back to look at the possibility of a widget.
The basemap that is used (which is normally just a cached map service) sets the maps LODs, which constrains the maps scales that are available to be zoomed to.
Sorry, but i'm still confused. By the map service, do you mean the basemap that is being used or the map created with all the layers etc? If the former I guess we're stumped as we can't control it; if the later can you do something in the map?
Having a widget for zoom to scale would be pretty simple. The issue is that when working with a Cached basemap you are confined to the cache LODs (levels of display. Scales that the map service was cached at). So If I were to develop a widget for this then most of the time you would not get an option to type the scale you desire because you would only be able to zoom to those pre-determined LODs (scales). So as a developer I would present a dropdown with those scales matching the LODs. In the rare circumstance that the app does not use a basemap then there could be a text input that the user could type any scale into (as that would now be possible).
Hi Rich. Thanks for that, but I'm a bit of a newbie; RF scale and LODS?
Mahoning County solved this issue for our cadastral team using an RF scale and the set scale LODS in the main config file. Look under the title, as a user scrolls with the mouse the true scale changes and this enables the print function to print to a set scale for output.
Hope this helps.
Rich
Good to see others would like it; a pity it's not been picked up yet. I suspect my request is slightly different to yours, as it's not just printing at a set scale, but actually viewing. Within our team we're used to viewing our mapped data at set scales, so you can instantly orientate yourself to relative feature sizes etc. Hence we like to know that this view is 1:20,000 not 1:10,000.
I would love to see this as well, and it would be nice to be able to create a list of scales and also let users pick their own absolute scale. Also it would be good to display scale ie 1:2,000 above the scale bar, as an option. Last, allow the display to have text with units the developers choose, like 1 inch = 100 feet. This has long been a user question and for now I have to show them how to go to Print, then Advanced, then click 'current' by Scale. Thus it would be helpful if scale was intuitive and discoverable.
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.