lakkadghat Posted May 1, 2004 Posted May 1, 2004 Hello, I am facing a problem in my application. This occurs when I synchronize data from one sql server to another via internet. The problem is only faced on Windows 98, ME and some versions of XP. It works perfectly on Windows 2000 computers. The Error occurs on the statement myDataadapter.Fill(myDataset,"myDatatable") Just for debugging i tried reducing the number of rows to be imported and the same codes ran fine but when the number of rows increased to 2000, (with almost 50 columns) then it gives the error. what i am doing is when the user clicks on Synchronize button, it synchronizes with the remote server and my code run's like this btnSynch.click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSynch.Click conn.Open() trans = conn.BeginTransaction() Try table1() ' Synchronizes table 1 table2() ' Synchronizes table 2 table3() ' Synchronizes table 3 Catch oExcept As Exception trans.Rollback() MsgBox(oExcept.Message) End Try and in these individual functions i have written all the codes for synchronization. but in win98 & ME it is not even catching the error that has occured and gives Unhandled Exception message. Shouldn't it catch the exception occured in the functions too ??? The Exception That I recieve is "This SqlTransaction has completed; it is no longer usable" Details : System.InvalidOperationException: This SqlTransaction has completed; it is no longer usable. at System.Data.SqlClient.SqlTransaction.Rollback() at MyProject.frmsynch.btnSynch_Click(Object sender, EventArgs e) at System.Windows.Forms.Control.OnClick(EventArgs e) at System.Windows.Forms.Button.OnClick(EventArgs e) at System.Windows.Forms.Button.PerformClick() at System.Windows.Forms.Form.ProcessDialogKey(Keys keyData) at System.Windows.Forms.Control.ProcessDialogKey(Keys keyData) at System.Windows.Forms.Control.ProcessDialogKey(Keys keyData) at System.Windows.Forms.Control.PreProcessMessage(Message& msg) at System.Windows.Forms.ThreadContext.System.Windows.Forms.UnsafeNativeMethods+IMsoComponent.FPreTranslateMessage(MSG& msg) And when i wrote the Try catch method in the table1() function, it gave me the Error "General Network Error. Please check your Netwok documentation." Please Help. Thanking You all and awaiting a prompt reply l@kk@dgh@t Quote
Moderators Robby Posted May 1, 2004 Moderators Posted May 1, 2004 Try setting pooling=false in your conn string Quote Visit...Bassic Software
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.