Thank you so much for your patience and generosity in explaing the basic idea behind multithreading. This provides a simple solution to the issue I ran into, trying to start a Timer on a given WinForm at the press of a button. The problem is that the Timer_tick never excecutes.
@philm53809 жыл бұрын
Thank you for simplifying this concept! My UIs are always frozen and my progress bars are always ghetto (i += 1 and refresh, etc.) Now I'm gonna learn about delegates and get professional up in here... Um, where's the next tutorial with the delegates? ... TeachMeComputer! My career is in your hands! What are delegates and how do I use them?! :(
@hdqxgxa13 жыл бұрын
Excellent tutorial. We appreciate the time that you take in developing and recording the tutorials. I also like the way you provide a quick explanation when you take "shortcuts" like the crossthreading check....for those critics out there....this is for Instructional Purposes Only due to time constraints..... Thanks again!
@AbishaiSingh3 жыл бұрын
Thanks for explaining the concept in a very simplified manner..
@stansarproductionz11 жыл бұрын
this scouser is great, explains complicated concepts with ease. keep it up!!!
@taarchi11 жыл бұрын
我非常喜欢你的教程关于线程,你的解释很清除! Thank you very mucch for your explanation, very clears, now I undestand crossthreading
@NathanaelCrapo12 жыл бұрын
I like this tutorial upto the part where you used the cross threading. i found a way around that without doing the delegate thing and it was simple enough for me to learn all on my own.
@Sc00rpY13 жыл бұрын
Just change quality to 720p and you will see the code on fullscreen :) Thanks for this tutorial, i looked for a way to pass that error on compiling
@TheColonel_10 жыл бұрын
Very nice, when googling this I just end up with something that has 29347692837492837492834 lines of code just to show one small example -.- This was very nice and simple, thanks.
@kevins17387 жыл бұрын
Very good example! very usable for high frequency transactions, reports, etc
@TeamOrtus12 жыл бұрын
Did you ever post the next tutorial explaining the use of delegates? If so any chance you can post where it's located as I can't seem to find it. Great tutorials... please keep adding more as they've helped me out alot. Many thanks :-)
@peekay6912 жыл бұрын
Thanks a lot for your tutorial! Where is the delagate tutorial you promised?
@gybersantos13 жыл бұрын
@TheCowWhoClutchd Timer executes the code inside it repeatedly with the delay of what the value of its Interval property. The thread executes the code parallel with the main thread. When we say parallel, it is executed at the same time...
@LosTecH8814 жыл бұрын
thanks man... nice tutorial again...cant wait for the next tutorial...
@ramasamyramasamy12 жыл бұрын
Thank you for video tutorial. After starting the thread you haven't mentioned anything about the thread abort or closing of thread. Hope it's necessary to abort the thread while closing the form. But Great work dude! Well done !
@lycosa200012 жыл бұрын
Thanks a lot for this.. I've been looking for a solution for VB's clunky timer control that opened, read, and then closed a serial port and my program froze each time the timer fired and it was really annoying me. This helped a ton!
@rogerbreton64124 жыл бұрын
I'm in the same boat! I need to show time elapsed in my Form for the user to know what's going on, because the time to send a command and receive a response from the RS-232 port can go from a few seconds to 10 minutes!
@ThePassingVoid9 жыл бұрын
You can also use "i += 1" to increment i by 1in the loop.
@ryasmi14 жыл бұрын
nice video, very descriptive and clear.
@hectormzt14 жыл бұрын
Thanks dude! i was looking for this
@emann12345613 жыл бұрын
thank you for making the tutorial even if 3-4AM
@henryjpr475611 жыл бұрын
Thanks MUCH! It's a shame you didn't do the "Threading Using Delegate" tutorial. There are other tutorials on the subject, but I'm having trouble when a thread, from a module, attempts to update a control on a form in the UI Thread. I see nothing on that.
@owlglazing10 жыл бұрын
Where is the Delegate post? My app is really big and multithreading doesn't work.
@NathanaelCrapo12 жыл бұрын
or use an Enum as a status keeper and use a timer specific to managing those other threads from the main thread which want to access controls on the main thread.
@ncc185312 жыл бұрын
I love the simplicity of the tutorial. Do you post your somewhere?
@MouraoRenato12 жыл бұрын
Excellent video. It`ll help me a lot in a project I`m developing. Thank you very much for the video.
@victornogueira83173 жыл бұрын
good video!!!! From GnSistemas!
@klynh1314 жыл бұрын
thx big time. right now the only way i knew how to multithread was though a background worker but this is ay better
@Machiavelli_000012 жыл бұрын
I appreciate your videos. Thanks for your work.
@wgh99913 жыл бұрын
Thanks for making it so basic!
@GhostMajoRX9 жыл бұрын
Tnx bro now im fixed my chat application auto refreshing... thank you a lot ;)
@50Hz10 жыл бұрын
That was very good..
@tilankak14 жыл бұрын
Thanks. Very helpfull
@oakbank19536 жыл бұрын
Nice and simple; just what the doctor ordered...:)
@misaik12 жыл бұрын
u can use delegate too for mor security
@untitledname518310 жыл бұрын
Great way to explain, thx
@hwatcha2412 жыл бұрын
great tutorial !
@Many_Mirrors14 жыл бұрын
Like you!
@denisikac3 жыл бұрын
Thank you
@danedavis509810 жыл бұрын
great video, thanks!
@Bulfoz13 жыл бұрын
Well done. thank you.
@matrixitalia757514 жыл бұрын
what the program 4 recording from desktop? :) thks nice video!
@peterschiller24518 жыл бұрын
Since VStudio 2012 it is possible to use Async with Await task.delay(xxx). It's much more easy to use. You can run as much threads as you want. Async Sub xxx() do until i >1000 I +=1 label1.text=i await task.delay(100) loop
@iRepTiLeZHD11 жыл бұрын
make a separate thread for each sub and try to break everything into subs so every action can have its space. for example : private sub compress1 choose file - end subprivate sub compress2 read file end sub - private sub compress3 write to file end sub - private sub compress4 compress end sub ___ then make a thread for each sub
@Vortex9313 жыл бұрын
Can you make a tutorial on how to make Server with ports and run on ip etc.. ??
@hscsoft_tutorials9 жыл бұрын
Masssive thank u for crosscheck solution.
@stonkwell13 жыл бұрын
yoink! cheers mate
@soulreaver496213 жыл бұрын
@5hunt3r it's just checkforillegalcrossthreadcalls = false
@eduardositedotcom12 жыл бұрын
thanks thanks thanks thanks. you are my new.cool.idol(Byval thebest)
@jeffb1122 Жыл бұрын
is that will work on datagridview?
@carstorm8513 жыл бұрын
So doing this I can make a game right? Because right now My game is laggy-like because only one thing moves at a time.
@fede14285712 жыл бұрын
Now, how do I run several pieces of the same code in different threads? I don't really know how to say it, so here is an example of what I want: Pretend I'm making a file compressor, but when I test it I find that it works too slowly (i.e. takes 2 minutes to compress a single 4MB file) and want to speed it up, say, at least 4 times as fast. How should I do that? Someone please reply.
@pivitman10114 жыл бұрын
thanks man this help me .
@iRepTiLeZHD11 жыл бұрын
actually, setting 'CheckForIllegalCrossThreadCalls' to false is important if your using multi-threading for security-purposes
@odonnaghan13 жыл бұрын
Thank you!
@HemmingEducation13 жыл бұрын
great
@TheMadHeadSeries12 жыл бұрын
How come a open file dialog is blank when run on a separate thread is it a bug?
@PaulNathan8212 жыл бұрын
Nice tutorial, thanks :-))
@flyrose96858 жыл бұрын
thank's men for this tutorial
@25DMTutorial11 жыл бұрын
I have just add an updater in my application with the help of your Video: VB.NET Tutorial 40; and so When I checked for update and then when I click anywhere on the form then the Form does not respond. (My internet connection is too slow, so that I causes the Problem While Checking for update too...) So please Help me
@roydolfje13 жыл бұрын
is there an way to make the countup faster
@njthemonsterIII14 жыл бұрын
quick explanation: Me.ChekForIllegalCallSigns = False ; He got this error because both threads were using a shared variable or component (in this case Me.Refresh), this error is to prevent multiple threads from modifying a common variable and thereby screwing eachother over. Me.refresh wont cause anything bad to happen if they cross. But beware, never use a common variable with Me.CheckForIllegalCallsSigns =False :D I shall make a video to explain this fully.
@엠에스티시스템9 жыл бұрын
Thanks.
@TMakawa26511 жыл бұрын
PlayThroughForYou why shouldnt we use that checkforillegalcrossthreadcalls = false...what could end up happening?
@Thapains14 жыл бұрын
@TheEpicNewb Do you have .net framework 4?
@leriosindane7203 жыл бұрын
Still Dop in 2021
@SlavaVB3 жыл бұрын
How come it counts up so slow washout a delay?
@geilereliasradillosarmient493610 жыл бұрын
and if to run two forms at once as I could do this using threads
@megascan6 жыл бұрын
Thx man
@ncc185312 жыл бұрын
your code somewhere?
@DJDexeee13 жыл бұрын
Guys Its not Me.CheckForIllegalCrossThreadCalls = False Its Control.CheckForIllegalCrossThreadCalls = False
@alfredcancio9827 жыл бұрын
i just wanted to know if is it possible that an array of multithreading?
@Mahekaru6 жыл бұрын
I wouldn't use an array try using a list try dim lstThreads = new list(of threads) then do lstthreads.add(). Keep in mind you'll need a loop like a for each loop to go through each thread and start them all. something like for each i in lstthreads i.start loop.
@sarthaksharma974610 жыл бұрын
Can I use Multi Threading to DDoS Websites also?
@BitSec10 жыл бұрын
agcourse u can
@5hunt3r13 жыл бұрын
little question ... tryed to add "Me.CheckForIllegalCrossThreadCalls = False" but VB2010 wont accept this .... anyone knows why ?
@stefanorevic51167 жыл бұрын
If i run multiple threads, how do i stop all of them in single button click?
@Mahekaru6 жыл бұрын
it's like if thread.isbusy then thread.stop or suspend something like that.
@destroyer77129 жыл бұрын
thx
@alialali3a13 жыл бұрын
Thankssssssssssssssssssss
@sputtnikk1112 жыл бұрын
How do i pass parentheses? It wont let me :/
@IMSSEvolution11 жыл бұрын
Add to form load Control.CheckForIllegalCrossThreadCalls = False THEN YOU WONT NEED Delgats
@pranays9410 жыл бұрын
You are from Liverpool,arent you? :P
@rogerbreton64124 жыл бұрын
Is that where his accent comes from? I thought, naively, "Scotland". But I'm French :-)
@Razorrule10 жыл бұрын
best way are Delegates instead of AllowCrossThreadCalls. (just want to say)
@Blubbz0rZ14 жыл бұрын
@swehunter2000 You can actually do that, leave me a pm with the exact error and I'll tell you a fix.
@MadMatty726 жыл бұрын
'DoEvents' statement inside loop would have allowed either button to work. Both loops would be running on same thread however. Explanation good except for allowing cross threading - very bad.
@rayags11 жыл бұрын
some tutorial where delegates use????? help me XD
@Blubbz0rZ14 жыл бұрын
@swehunter2000 Form.Show / Form.ShowDialog Put control.checkforillegalcrossthreadcalls = False on startup
@silentcod3r12 жыл бұрын
Agreed. Using this approach seems bad practice and it's a lazy programmers approach.
@MadMatty726 жыл бұрын
DoEvents
@gamenew0913 жыл бұрын
@rich2600rich2600 Check if you muted on your computer and the KZbin player.
@Irishsam12 жыл бұрын
Teaching yours to use check for illegal cross threads is just unforgivable. As your project grows and becomes more complex tracking down bugs may become harder. You can leave your self with race conditions or deadlocks. You should never be setting CheckForIllegalCrossThreadCalls to False. Whenever you have a need to access a control from a thread other than the UI thread, you should use a delegate to invoke a method.
@PlayThroughForYou11 жыл бұрын
It would send many errors later on, all its doing is saying even if the application finds an error it would keep going, this is a bad thing. you want to invoke your threads rather than not checking for errors. look up invoking tutorials for real multi-threading. This is just the slum way of doing things and is really bad.
@toneation13 жыл бұрын
Thanks,please zoom ; )
@bubba66472 жыл бұрын
Doing two bad functions at the same damn time.....
@nemanja74711 жыл бұрын
I CANT SEE SHIT!!!
@PlayThroughForYou11 жыл бұрын
NO NO NO NO NO, Me.CheckforIllegalCrossThreadCalls = false IS A BAD HABBIT, do not watch this! Can cause many issues later on. I love your tutorials but do not listen to this one!