By default, when I set the LocationDisplay.AutoPanMode to Recenter, the map automatically pans so that my current location sits at the center of the MapView control. Is it possible somehow to provide an X,Y offset to the MapView so that Runtime adjusts where it thinks the visual center is? In my application, I sometimes display a panel of information that floats above the left side of the map. When this panel is open, I would like to shift the visual center of the map over to the right a certain amount to accommodate the panel. I realize that I could split the screen vertically into into two separate sections - one for my panel and one for the map. Then I could hide the panel section when it's not needed and let the map consume the entirety of the screen. The downside to this approach is that 1) my panel doesn't usually need the full vertical portion of the screen and 2) there is a jarring effect as the map is repainted in the newly available space when the panel is closed, which gets worse if the panel is opened and closed a lot. I'm using the ArcGIS Runtime SDK for .NET v100.8. TheMapView.LocationDisplay.AutoPanMode = LocationDisplayAutoPanMode.Recenter Thank you!
... View more
Thank you for posting this question. Can you explain a bit more about what to expect in the return value for PopulateFromServiceAsync vs QueryFeaturesAsync if the feature layer that I'm querying from doesn't have an Object ID field defined? In my situation (using ArcGIS Runtime 100.7), I have created two ServiceFeatureTable objects, each set to ManualCache request mode and pointing to a couple of different feature layers on ArcGIS server. I'm using these to periodically poll for data. I'm seeing different behavior between the two, and I think it has to do with the presence (or lack of) an Object ID field. The first layer has an object ID field, and PopulateFromServiceAsync returns the results as expected. The second layer does not have an object ID field, and PopulateFromServiceAsync returns no results, even though I know there are results on the server. However, QueryFeaturesAsync correctly returns the results I was expecting, but ONLY IF I call PopulateFromServiceAsync first. Not sure if it makes any difference, but I have the clearCache parameter set to true on the call to PopulateFromServiceAsync. It seems like internally the ServiceFeatureTable is populating the data, but isn't returning those results if the layer doesn't have an Object Id field defined. This was what threw me off. My solution was to call PopulateFromServiceAsync, then do a check to see if the ServiceFeatureTable.ObjectIdField is blank, and if so, call QueryFeaturesAsync to get the data in the table. Does this seem like a good approach (in lieu of the ideal solution of adding an Object Id field)? Thanks.
... View more