PPC + wlan --> Connectionproblem

PPC + wlan --> Connectionproblem

Postby donnyriyadi » Wed 25 May 2005 10:44

Hi,
I'm now trying to use pgsql DA on the CF.
If the Wlan connection is broken, and I cannot send any query anymore. What should I do, so that I can be connected automatically again ?
Thanks.
donnyriyadi
 

PPC + wlan --> Connectionproblem

Postby Yuri » Fri 27 May 2005 08:34

There is no way to connect automatically. You should reconnect after an exception has been thrown.
Code: Select all
try {
        pgSqlDataAdapter.Fill(dataSet, "Table");  // pgSqlDataAdapter.SelectCommand.Connection.State ==  ConnectionState.Open
        dataGrid.DataMember = "Table";

      }
      catch {
        pgSqlDataAdapter.SelectCommand.Connection.Open();
        pgSqlDataAdapter.Fill(dataSet, "Table");
        dataGrid.DataMember = "Table";
      }
Yuri
 
Posts: 140
Joined: Mon 08 Nov 2004 12:07


Return to dotConnect for PostgreSQL