problem to connect to a SQL Server 2000 database

G

Guest

Hello,

I want to connect a mobile computer with windows CE 4.2 to a Sql Server 2000
running on a windows XP desktop.

Here my code:

SqlConnection mConnection = new SqlConnection();
mConnection.ConnectionString = "user id=sa;data source=SFH503940W2K;persist
security info=True;initial catalog=IDPS;password=xxx";

try
{
mConnection.Open();
}
catch (Exception e)
{
MessageBox.Show(e.Message, "Database connection error",
MessageBoxButtons.OK,MessageBoxIcon.None,MessageBoxDefaultButton.Button1);
}

this code works well on a desktop computer but on the mobile computer a
"PlatformNotSupportedException" is caught

the projet is well configured because without using the database, all
applications work fine.

And I'm using the System.Data.SqlClient.dll from the .NET Compact Framework
to connect the database

What is the problem ? can someone help me ?
Where can I find informations ?
 
H

Hector Obregon [eMVP]

Hi Christian,

We have gotten this error in the past due to the specific regional
configuration of the Windows CE.NET build, though we got it when
deserializing a DataSet on the client. You might want to check that out.

Cheers

Hector
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top