Deutsch
Bug-Nummer BUG-000082172
Erzeugt am Sep 25, 2014
Modified Apr 09, 2019
Schweregrad Low
Übernehmen für ArcGIS Runtime SDK for WPF
Gefundene Version 10.2.3
Progr.-Sprache n. z.
Server-Plattform
Client-Plattform
Datenbank n. z.
Gebietsschema n. z.
Status Implemented
Behoben in Version Q1 2015
SP Fixed N/A

Bug BUG-000082172

Zusammenfassung

MapControl properties bound to text elements fail to update when zooming in an ArcGIS Runtime SDK for WPF application.


Zusätzliche Informationen

n. z.


Alternative Lösung

1. Manually update the text shown in the application by listening for the ExtentChanged property of the map.


2. Write a value converter, to bind the Map.Extent to, but pass the map's instance as a converter parameter to the class and return the scale as the value.


3. Wrap the map. For example:


<TextBlock x:Name="ScaleText" Text="{ Binding ElementName=MyMap, Path=Extent, Converter={StaticResource SC}, ConverterParameter={x:Reference Name=MyMap}}" FontSize="12" FontWeight="Bold" Foreground="Black"/>


public class SC : IValueConverter

{

public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)

{

double scale = 0.0;


if (parameter is Map) scale = ((Map)parameter).Scale;


return scale;

}


public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)

{

return value;

}

}