thread closing connection
-
Hey im having a problem with threads and Connections. When the user loging to my program im trying to update the status bar. just a small loop that will run for 7 sec (avg), but when im sending the loging info to the database with a thread, the thread is closing my connection and fail. *.when im not using threads all working good. *.im using oracle 8 database. *.is there someting i need to do with the connection string ? btw i know how to work with threads it's just dont working with a connections
-
Hey im having a problem with threads and Connections. When the user loging to my program im trying to update the status bar. just a small loop that will run for 7 sec (avg), but when im sending the loging info to the database with a thread, the thread is closing my connection and fail. *.when im not using threads all working good. *.im using oracle 8 database. *.is there someting i need to do with the connection string ? btw i know how to work with threads it's just dont working with a connections
michael@cohen wrote:
i know how to work with threads
Are you sure? Try it without the status bar update, and if that runs fine, start using Control.InvokeRequired and Control.Invoke (plenty of examples around). :)
Luc Pattyn [Forum Guidelines] [My Articles]
this weeks tips: - make Visual display line numbers: Tools/Options/TextEditor/... - show exceptions with ToString() to see all information - before you ask a question here, search CodeProject, then Google