File and Serial Port GPS Layer and KML file layer

Discussion created by ann-sofie on Dec 20, 2011
Latest reply on Jan 12, 2012 by MBranscomb-esristaff

I have installed ArcGIS Runtime 10.1 beta 2. I am now trying to add a GPSLayer to my map. The Sample Applications got errors until I changed the decimal separator to dot in my regional settings. But now after this change I still can't get it to work in my own project. I have tried using the same data as in the Sample Applications and similar code, but I get the following error:

A call to PInvoke function 'ESRI.ArcGIS.Client.Local!ESRI.ArcGIS.Client.Local.Gps.NativeMethods::GpsDriver_GetStatus' has unbalanced the stack. This is likely because the managed PInvoke signature does not match the unmanaged target signature. Check that the calling convention and parameters of the PInvoke signature match the target unmanaged signature.

For the Serial Port GPS sample code the error is the same but with
and occurs when calling SerialPortGpsCoordinateWatcher.FindGPSEnabledPort.

Anyone who has been able to get this work? Is there anything I can do to get this error fixed? Have my ArcGIS Runtime installation failed for some parts (I had to browse for the Toolkit dll when adding the referense, it was not listed among the ESRI dll:s)?

I am also trying to read data from a KML file with KmlLayer.SetSource, but here I haven't found any examples or help on how to do it. I don't get any errors, but no data either. When I try to read the stream CanRead is false. Anyone who can help me with this one?