Quantcast
Channel: Recent Threads — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 204402

Using System.Net.NetworkInformation.NetworkChange throws type initialization exception

$
0
0

Hello,

I have just updated to latest everything (Xamarin Studio 4.0.10, Xamarin.iOS 6.4.0.2, Xcode 4.6.3). Things are working again in my iOS simulator, so kudos to the Xamarin team. I am now getting this error when attempting to use the NetworkChange.NetworkAvailability and NetworkChange.NetworkAddressChanged events:

2013-07-25 14:59:59.681 SmartDeviceApp[79429:9807] INFO - [PROXY] Ex: System.TypeInitializationException: An exception was thrown by the type initializer for System.Net.NetworkInformation.NetworkChange ---> System.EntryPointNotFoundException: mono_sc_reachability_enabled
at (wrapper managed-to-native) System.Net.NetworkInformation.MacNetworkChange:mono_sc_reachability_enabled ()
at System.Net.NetworkInformation.MacNetworkChange.get_IsEnabled () [0x00000] in /Developer/MonoTouch/Source/mono/mcs/class/System/System.Net.NetworkInformation/NetworkChange.cs:66
at System.Net.NetworkInformation.NetworkChange..cctor () [0x00000] in /Developer/MonoTouch/Source/mono/mcs/class/System/System.Net.NetworkInformation/NetworkChange.cs:46
--- End of inner exception stack trace ---

I have tested this in a new barebones project, running against Mono 3.2, just using the event:

NetworkChange.NetworkAvailabilityChanged += new<br /> NetworkAvailabilityChangedEventHandler(NetworkAvailabilityChangedHandler);<br />

Is there something wrong with my project references? They are still the same as before my update (System, System.Core etc. are still 2.0.5.0)

Thanks,
Vernon


Viewing all articles
Browse latest Browse all 204402

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>