Win CE通过网络连接到SQL服务器 [英] Win CE connect to SQL server from by network

查看:173
本文介绍了Win CE通过网络连接到SQL服务器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hello All,



我对使用SQL服务器的Win CE(紧凑框架)有疑问。



i在Win CE中使用紧凑框架编写程序,我将使用窗口身份验证通过网络连接SQL服务器(WIFI)。大多数时候程序可以连接到服务器,但有时PDA无法连接到服务器。(很少发生)

一旦发生,那么生产将变得混乱,下面是例外:



我得到的SQLexception是 - 一般网络错误。请查看您的网络文档。



这里是堆栈跟踪:



在System.Data.SqlClient.SqlConnection.OnError()

在System.Data.SqlClient.SqlInternalConnection.OnError()

at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning()

在System.Data.SqlClient.TdsParser。 ReadNetlib()

在System.Data.SqlClient.TdsParser.ReadBuffer()

在System.Data.SqlClient.TdsParser.ReadByte()

在System.Data.SqlClient.TdsParser.Run()

在System.Data.SqlClient.SqlInternalConnection.Login()

在System.Data.SqlClient.SqlInternalConnection。 SystemAData.SqlClient.SqlI中的OpenAndLogin()

nternalConnection..ctor()

at System.Data.SqlClient.SqlConnection.Open()

at MAX_DKNYI.login.btnLogin_Click()

在System.Windows.Forms.Forms.OnClick()

在System.Windows.Forms.Button.OnClick()

在System.Windows.Forms.ButtonBase.WnProc ()

at System.Windows.Forms.Control._InternalWnProc()

at Microsoft.AGL.Forms.EVL.EnterMainLoop()

在System.Windows.Forms.Application.Run()


i从MSDN获得一些建议,但它看起来不适合我。 (它提到升级服务器的服务包或修补程序)

但是我试图改变PDA连接中的不同测试服务器,它仍然是相同的,所以大多数不是服务器问题。



i使用窗口身份验证方法连接到具有域名的服务器。示例如下;

数据源= 192.168.1.10;初始目录= MyNewDB;集成安全性= SSPI;用户ID = DOMAINNAME \ testuser;密码= testpassword;

i相信现在不是域名问题,但不知道如何解决。





希望有人可以为此提供一些想法/解决方案。

谢谢

Hello All,

I have a question regarding the Win CE(compact framework) with SQL server.

i writing a program by using compact framework in Win CE, i will use window authentication to connect SQL server by network(WIFI). most of the time the program can connect to the server, but sometime the PDA unable to connect to the server.(seldom happen)
once it happen then the production will become messy, below is the exception:

i get the SQLexception is - "General network error. Check your network documentation".

here is stack-trace :

at System.Data.SqlClient.SqlConnection.OnError()
at System.Data.SqlClient.SqlInternalConnection.OnError()
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning()
at System.Data.SqlClient.TdsParser.ReadNetlib()
at System.Data.SqlClient.TdsParser.ReadBuffer()
at System.Data.SqlClient.TdsParser.ReadByte()
at System.Data.SqlClient.TdsParser.Run()
at System.Data.SqlClient.SqlInternalConnection.Login()
at System.Data.SqlClient.SqlInternalConnection.OpenAndLogin()
at System.Data.SqlClient.SqlInternalConnection..ctor()
at System.Data.SqlClient.SqlConnection.Open()
at MAX_DKNYI.login.btnLogin_Click()
at System.Windows.Forms.Control.OnClick()
at System.Windows.Forms.Button.OnClick()
at System.Windows.Forms.ButtonBase.WnProc()
at System.Windows.Forms.Control._InternalWnProc()
at Microsoft.AGL.Forms.EVL.EnterMainLoop()
at System.Windows.Forms.Application.Run()

i get some suggestion from the MSDN but it look like not really suit to me. (it mention upgrade the server's service pack or hotfix)
but i have try to change the different testing server in the PDA connection, it still the same, so mostly is not the server problem.

i using window authentication method to connect to server with the domain name. example as below;
Data Source=192.168.1.10;Initial Catalog=MyNewDB;Integrated Security=SSPI;User ID=DOMAINNAME\testuser;Password=testpassword;
i believe now is not the domain problem, but don't know how to settle.


hopefully someone can provide some idea/solution for this.
thanks

推荐答案

这是不可能的!

查看我过去的回答: Sql server2005的Window CE 5.0连接 [ ^ ]


这篇关于Win CE通过网络连接到SQL服务器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆