requested address is not valid in its context
Posted: Thu 21 Sep 2017 15:13
Hello Devart and users,
I use dotConnect Mobile in a VB.Net Project, running on WindowsMobile 6.5.3, with a connection to a PostgreSQL 8.3.8 database running on Win2003 Server.
I use a simple code for connection:
Public myConnstring As String = "host=192.168.178.66;User Id=admin;Password=123;Database=mydb;Port=5432;"
Public WithEvents myPgSqlConnection As Devart.Data.PostgreSql.PgSqlConnection
myPgSqlConnection = New Devart.Data.PostgreSql.PgSqlConnection
myPgSqlConnection.ConnectionString = myConnstring
myPgSqlConnection.ConnectionTimeout = 200
myPgSqlConnection.Open()
Everything works fine, if my Mobile-Device is directly connected to the Server over USB.
If I connect the Mobile-Device over WLAN I get the exception:
Devart.Data.PostgreSQL.PGSqlException: the requested address is not valid in its context
The WLAN-Connection works, I can ping the Server, connect to the internet and so on.
My Device has a IP-V4-Adress containing to the same Network.
Thanks a lot for your help!
I use dotConnect Mobile in a VB.Net Project, running on WindowsMobile 6.5.3, with a connection to a PostgreSQL 8.3.8 database running on Win2003 Server.
I use a simple code for connection:
Public myConnstring As String = "host=192.168.178.66;User Id=admin;Password=123;Database=mydb;Port=5432;"
Public WithEvents myPgSqlConnection As Devart.Data.PostgreSql.PgSqlConnection
myPgSqlConnection = New Devart.Data.PostgreSql.PgSqlConnection
myPgSqlConnection.ConnectionString = myConnstring
myPgSqlConnection.ConnectionTimeout = 200
myPgSqlConnection.Open()
Everything works fine, if my Mobile-Device is directly connected to the Server over USB.
If I connect the Mobile-Device over WLAN I get the exception:
Devart.Data.PostgreSQL.PGSqlException: the requested address is not valid in its context
The WLAN-Connection works, I can ping the Server, connect to the internet and so on.
My Device has a IP-V4-Adress containing to the same Network.
Thanks a lot for your help!