0
私のプログラムは、Windows Server 2003およびFramework 4.0のWindows XPで問題なく動作していました。私たちはもうコンピュータ上でWindows 7を使用します。プログラムがデータベースに接続しようとすると、ログインに失敗したというエラーが表示されます。クライアントまたはサーバー上で何かを変更する必要がありますか?Windowsからの接続用SQL Serverの設定7
エラーメッセージは次のとおりです。
Login failed. the login is from an untrusted domain and cannot be used with windows authentication
Bu iletişim kutusu yerine JIT hata ayıklamayı çağırma hakkında detaylı bilgi için bu iletinin sonuna bakın.
************** Özel Durum Metni ************** System.Data.SqlClient.SqlException (0x80131904): Login failed. The login is from an untrusted domain and cannot be used with Windows authentication. konum: System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection) konum: System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection) konum: System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection) konum: System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions) konum: System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource`1 retry) konum: System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry) konum: System.Data.SqlClient.SqlConnection.Open() konum: stokKontrol.Form1.dbBaglan() C:\Users\Dell\Documents\Visual Studio 2015\Projects\stokKontrol\stokKontrol\Form1.cs içinde: satır 291 konum: stokKontrol.Form1.cariOtoDoldur() C:\Users\Dell\Documents\Visual Studio 2015\Projects\stokKontrol\stokKontrol\Form1.cs içinde: satır 44 konum: stokKontrol.Form1.Form1_Load(Object sender, EventArgs e) C:\Users\Dell\Documents\Visual Studio 2015\Projects\stokKontrol\stokKontrol\Form1.cs içinde: satır 1370 konum: System.Windows.Forms.Form.OnLoad(EventArgs e) konum: System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible) konum: System.Windows.Forms.Control.CreateControl() konum: System.Windows.Forms.Control.WmShowWindow(Message& m) konum: System.Windows.Forms.Control.WndProc(Message& m) konum: System.Windows.Forms.Form.WndProc(Message& m) konum: System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam) ClientConnectionId:824f06ba-5b8e-455a-9ef8-e53dfe23608c Error Number:18452,State:1,Class:14
************** Yüklü Derlemeler ************** mscorlib
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.34209 built by: FX452RTMGDR
CodeBase: file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/mscorlib.dll
---------------------------------------- stokKontrol
Derleme Sürümü: 1.0.0.0
Win32 Sürümü: 1.0.0.0
CodeBase: file://Gunes/d$/gunluk_rapor/addOns/bltBin/stokKontrol/stokKontrol/bin/Debug/stokKontrol.exe
---------------------------------------- System.Windows.Forms
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.34251 built by: FX452RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
---------------------------------------- System.Drawing
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.34270 built by: FX452RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
---------------------------------------- System
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.34238 built by: FX452RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
---------------------------------------- System.Windows.Forms.resources
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.18408 built by: FX451RTMGREL
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms.resources/v4.0_4.0.0.0_tr_b77a5c561934e089/System.Windows.Forms.resources.dll
---------------------------------------- System.Configuration
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.34209 built by: FX452RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
---------------------------------------- System.Xml
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.34234 built by: FX452RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
---------------------------------------- System.Data
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.34209 built by: FX452RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_64/System.Data/v4.0_4.0.0.0__b77a5c561934e089/System.Data.dll
---------------------------------------- System.Transactions
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.34209 built by: FX452RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_64/System.Transactions/v4.0_4.0.0.0__b77a5c561934e089/System.Transactions.dll
---------------------------------------- System.EnterpriseServices
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.34209 built by: FX452RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_64/System.EnterpriseServices/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.EnterpriseServices.dll
---------------------------------------- mscorlib.resources
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.18408 built by: FX451RTMGREL
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/mscorlib.resources/v4.0_4.0.0.0_tr_b77a5c561934e089/mscorlib.resources.dll
---------------------------------------- System.Data.resources
Derleme Sürümü: 4.0.0.0
Win32 Sürümü: 4.0.30319.18408 built by: FX451RTMGREL
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Data.resources/v4.0_4.0.0.0_tr_b77a5c561934e089/System.Data.resources.dll
----------------------------------------
************** JIT Hata Ayıklama ************** JIT hata ayıklamayı etkinleştirmek için, bu uygulamanın veya bilgisayarın (machine.config) .config dosyasında system.windows.forms bölümünde jitDebugging değeri ayarlanmış olmalıdır. Ayrıca uygulama hata ayıklama etkin durumdayken derlenmiş olmalıdır.
Örneğin:
<configuration>
<system.windows.forms jitDebugging="true" /> </configuration>
JIT hata ayıklama etkinken, işlenmemiş özel durumlar bu iletişim kutusunda işlenmek yerine bilgisayarda kayıtlı JIT hata ayıklayıcısına gönderilir.
クライアントが接続に使用する接続文字列を入力してください。プログラムが実行されるとき、実行されているユーザーアカウントは何ですか?間違いなくドメインユーザーですか? –
私はこの文字列を接続に使用します。 conString = "サーバー= GNS;データベース= GNSデータベース;ユーザーID =ユーザー;パスワード= 123456; Trusted_Connection = true" – Bulut