We get some crash reports sometimes that we don't quite understand.
I understand that there are times when the MapView is not ready to return information like Scale and VisibleArea.
But how do I tell when it is safe? Crashing isn't very user friendly.
Example 1:
Sure there are times when the scale can't be read. But I don't think one of those times should be when you just called us to tell us the scale changed. That seems like a time when we can get a scale and update the zoomlevel. But nope, it crashes. Not all the time, but some of the time.
A bit ridiculous?
Is there some method available like boolean MapView isItSafetoAskforScale() ?
Because the only other alternative I can think of is to handle an exception every time we call MapView.getMapScale().
Or just let it crash.
Hi Nathan,
Can you share more details to help us reproduce this problem? I can access the MapView's scale OK in a MapScaleChangedListener, and I'm using ArcGIS Runtime SDK for Android 100.3. Let us know about your device, which version of Android you have, and ideally some simple code that shows the problem for you.
Regards,
Shelly