Select to view content in your preferred language

Overriding scale ranges in ArcGIS Desktop, problem with SaveDefaultUserScales() ?

674
0
09-13-2016 07:40 AM
LeoSavoie
New Contributor

I've overridden the default scale range using ArcObjects 10.2 in ArcMap 10.2.1 .

IDisplayTransformationScales displayTransformationScale = (IDisplayTransformationScales)pActiveView.ScreenDisplay.DisplayTransformation;
displayTransformationScale.RemoveAllUserScales();

foreach (UtmZone20Enum utmZone20Enum in Enum.GetValues(typeof(UtmZone20Enum)))
{displayTransformationScale.AddUserScale((double)utmZone20Enum);}

displayTransformationScale.SaveDefaultUserScales();

[...]

pActiveView.ContentsChanged();
pActiveView.Refresh();

The range looks fine in the "Scale Settings" dialog , but it doesn't get refreshed to the actual "Map Scale" dropdown listbox when I call SaveDefaultUserScales() on the IDisplayTransformationScales interface.

IDisplayTransformationScales.SaveDefaultUserScales Method (ArcObjects .NET 10.1 SDK) 

If I click on OK in the Scale Settings Dialog, it does get updated.

Is there a known problem with the SaveDefaultUserScales() method ?

Scale Settings dialog with changed scale range.

Thanks for any info.

0 Kudos
0 Replies