任何人都看到此错误

任何人都看到此错误

本文介绍了任何人都看到此错误:System.Data.OleDb.OleDbException:对象已打开的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

完整的StackTrace():

The complete StackTrace():

Error: System.Data.OleDb.OleDbException: Object was open. at System.Data.OleDb.OleDbConnectionInternal..ctor(OleDbConnectionString constr, OleDbConnection connection) at System.Data.OleDb.OleDbConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject) at System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup) at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) at System.Data.OleDb.OleDbConnection.Open() at Microsoft.Practices.EnterpriseLibrary.Data.Database.GetNewOpenConnection() at Microsoft.Practices.EnterpriseLibrary.Data.Database.GetOpenConnection(Boolean disposeInnerConnection) at Microsoft.Practices.EnterpriseLibrary.Data.Database.LoadDataSet(DbCommand command, DataSet dataSet, String[] tableNames) at Microsoft.Practices.EnterpriseLibrary.Data.Database.LoadDataSet(DbCommand command, DataSet dataSet, String tableName) at Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteDataSet(DbCommand command) at DataAccess.Check_Web_Snapshot_Current_Exists(String original_cn)<br />



我用谷歌搜索,没有发现与对象被打开"有关的东西.该应用程序使用模拟功能,似乎仅当我以用户身份从另一个域登录时才会发生.当我使用本地帐户时,看不到此信息.

但是,当我使用本地帐户登录计算机并且在登录提示符下使用其他域的凭据登录时,我看不到它.当它在本地不起作用时,很难调试,并且在我的日志中抛出的唯一错误就是上面的错误.

有什么主意吗?
谢谢.



I googled for it and found nothing pertaining to ''Object was Open''. The application uses impersonation and seems to only happen when I am logged in as a user from another domain. When I am using my local account I don''t see this.

However, I don''t see it when I log into the computer using a local account AND at the login prompt use the other domain''s credentials to log in. If that makes sense. It''s hard to debug when it doesn''t work locally and the only error being thrown in my logs is the one above.

Any idea''s?
Thanks.

推荐答案

conn.Open()

之前关闭连接.似乎当一个连接已经打开时,您正在打开一个新的连接.也许有帮助.

. Seems like you are opening a new connection when there is a connection already open. Maybe helpful.


这篇关于任何人都看到此错误:System.Data.OleDb.OleDbException:对象已打开的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-23 23:05