Click here to Skip to main content
16,004,991 members
Home / Discussions / Visual Basic
   

Visual Basic

 
QuestionBrowser Activity Pin
AndyASPVB18-Apr-09 5:00
AndyASPVB18-Apr-09 5:00 
AnswerRe: Browser Activity Pin
Eddy Vluggen18-Apr-09 22:48
professionalEddy Vluggen18-Apr-09 22:48 
QuestionDisable some hot keys Pin
AndyASPVB18-Apr-09 4:57
AndyASPVB18-Apr-09 4:57 
AnswerRe: Disable some hot keys Pin
Zaegra18-Apr-09 5:36
Zaegra18-Apr-09 5:36 
AnswerRe: Disable some hot keys Pin
Eddy Vluggen18-Apr-09 6:57
professionalEddy Vluggen18-Apr-09 6:57 
AnswerRe: Disable some hot keys Pin
Mycroft Holmes18-Apr-09 17:22
professionalMycroft Holmes18-Apr-09 17:22 
GeneralRe: Disable some hot keys Pin
AndyASPVB18-Apr-09 22:41
AndyASPVB18-Apr-09 22:41 
QuestionRefreshing the UI during a long process using VB.NET 3.5 without Application.DoEvents - believe me Ive tried! Pin
Marcus J. Smith18-Apr-09 4:14
professionalMarcus J. Smith18-Apr-09 4:14 
I have an application that has a simple user interface but quite a bit of code under the hood. The interface is a file processing form where the user chooses a file and then clicks a button to process the selection. The code disables all buttons on the form and has at it. Quite a bit of the code is reading from the file and I report how many records every 100 count and then call Application.DoEvents (I know this is bad that is why I am here).

Part of this application uses BackGroundWorkers to run long SQL queries/updates where I use the .IsBusy property in a while loop and update a time elapsed message then call Application.DoEvents. I have a continuous progress bar that just runs all the time to show that something is happening but not necessarily reporting actual progress.

I also have true multi-threading where I kick off threads and I have a few steps in the process where I wait for a few of those threads to complete before starting others, as part of that waiting process I call the Application.DoEvents call again.

I have found many many articles online and forums where people say not to use Application.DoEvents, you should use backgroundworkers with ProgressChanged events. Well even though I implemented the Delegate step that they mention to set the value on the status bar for time elapsed, as soon as I take out the Application.DoEvents the form will report that it is not responding and if the user clicks on it they get the typical whited out form.

What should I use instead to guarantee that I dont have code stepping on itself?


CleaKO

"Now, a man would have opened both gates, driven through and not bothered to close either gate." - Marc Clifton (The Lounge)

QuestionRe: Refreshing the UI during a long process using VB.NET 3.5 without Application.DoEvents - believe me Ive tried! Pin
Eddy Vluggen18-Apr-09 6:51
professionalEddy Vluggen18-Apr-09 6:51 
AnswerRe: Refreshing the UI during a long process using VB.NET 3.5 without Application.DoEvents - believe me Ive tried! Pin
Luc Pattyn18-Apr-09 7:15
sitebuilderLuc Pattyn18-Apr-09 7:15 
AnswerRe: Refreshing the UI during a long process using VB.NET 3.5 without Application.DoEvents - believe me Ive tried! Pin
Luc Pattyn18-Apr-09 7:22
sitebuilderLuc Pattyn18-Apr-09 7:22 
QuestionMouse-event Improvement Pin
User 584223717-Apr-09 23:33
User 584223717-Apr-09 23:33 
AnswerRe: Mouse-event Improvement Pin
Eddy Vluggen18-Apr-09 0:24
professionalEddy Vluggen18-Apr-09 0:24 
GeneralRe: Mouse-event Improvement Pin
User 584223718-Apr-09 1:24
User 584223718-Apr-09 1:24 
GeneralRe: Mouse-event Improvement Pin
Eddy Vluggen18-Apr-09 1:33
professionalEddy Vluggen18-Apr-09 1:33 
GeneralRe: Mouse-event Improvement Pin
User 584223718-Apr-09 5:03
User 584223718-Apr-09 5:03 
GeneralRe: Mouse-event Improvement Pin
Eddy Vluggen18-Apr-09 5:52
professionalEddy Vluggen18-Apr-09 5:52 
GeneralRe: Mouse-event Improvement Pin
User 584223718-Apr-09 6:22
User 584223718-Apr-09 6:22 
GeneralRe: Mouse-event Improvement Pin
Eddy Vluggen18-Apr-09 6:50
professionalEddy Vluggen18-Apr-09 6:50 
GeneralRe: Mouse-event Improvement Pin
Mycroft Holmes18-Apr-09 2:03
professionalMycroft Holmes18-Apr-09 2:03 
AnswerRe: Mouse-event Improvement [modified] Pin
Johan Hakkesteegt20-Apr-09 2:39
Johan Hakkesteegt20-Apr-09 2:39 
GeneralRe: Mouse-event Improvement Pin
User 584223725-Apr-09 5:45
User 584223725-Apr-09 5:45 
QuestionHow can i create salary format in Textbox ? for example i want create 2000.00 . Pin
pramod251717-Apr-09 19:55
pramod251717-Apr-09 19:55 
AnswerRe: How can i create salary format in Textbox ? for example i want create 2000.00 . Pin
Rajesh Anuhya17-Apr-09 20:08
professionalRajesh Anuhya17-Apr-09 20:08 
AnswerRe: How can i create salary format in Textbox ? for example i want create 2000.00 . Pin
Andy_L_J17-Apr-09 22:16
Andy_L_J17-Apr-09 22:16 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.