I am getting an error when trying to connect. I am only testing with the xamarin.ios project. I realize that connecting to a sql database over the internet is not a good idea. However, in my case the application connects only to a local database on a company network using a wifi connection.
Error when running with the ios simulator:
System.TypeInitializationException: 'The type initializer for 'Microsoft.Data.SqlClient.TdsParser' threw an exception.'
2020-11-27 13:54:11.795508-0800 TmMobile.iOS[22564:1043002]
Unhandled Exception:
System.TypeInitializationException: The type initializer for 'Microsoft.Data.SqlClient.SNILoadHandle' threw an exception. ---> System.DllNotFoundException: sni.dll assembly:<unknown assembly> type:<unknown type> member:(null)
at (wrapper managed-to-native) Microsoft.Data.SqlClient.SNINativeMethodWrapper.SNIInitialize(intptr)
at Microsoft.Data.SqlClient.SNINativeMethodWrapper.SNIInitialize () [0x00000] in H:\tsaagent4_work\2\s\src\Microsoft.Data.SqlClient
etcore\src\Interop\SNINativeMethodWrapper.Windows.cs:289
...
