ThinkGeo.com    |     Documentation    |     Premium Support

Problem with MapPrinterLayer after upgrade to 14.5.0

In our application we have overridden the DrawCore method. After upgrading to 14.5.0 we now get an exception when calling MyBase.DrawCore:

System.MissingMethodException
HResult=0x80131513
Message=Method not found: ‘Void ThinkGeo.Core.GeoCanvas.DrawWorldImage(ThinkGeo.Core.GeoImage, Double, Double, Single, Single, ThinkGeo.Core.DrawingLevel)’.
Source=ThinkGeo.Printers
StackTrace:
at ThinkGeo.Core.MapPrinterLayer.DrawCore(GeoCanvas canvas, Collection1 labelsInAllLayers) at MapUtilities.CustomMapPrinterLayer.DrawCore(GeoCanvas canvas, Collection1 labelsInAllLayers) in C:\Silvics\SpatialAI TG 14\SpatialAI\MapUtilities\Classes\CustomMapPrinterLayer.vb:line 188
at ThinkGeo.Core.Layer.xCA=(GeoCanvas canvas, Collection`1 labelsInAllLayers)

If I take out the override altogether, I see the following:

Can you help me with this?

Thanks!

Steve

Hi Steve,

There’s a binary breaking change here: the old API was

GeoCanvas.DrawWorldImage(ThinkGeo.Core.GeoImage, Double, Double, Single, Single, ThinkGeo.Core.DrawingLevel)

In the new version, we added one more parameter at last:

GeoCanvas.DrawWorldImage(..., RasterResamplingMode resamplingMode = RasterResamplingMode.Auto)

The existing code would work fine with the new dll, but it will have that method not found exception if you just replace the old dll in the bin folder. Just rebuild your application and it should be fine.

Thanks,
Ben