Re: MultiThreading in vb6
Re: MultiThreading in vb6
I could be wrong but I don't think you can multi-thread in VB6. You can create several thread-like instances but they will only run one at a time and not multi-threaded in the conventional sense (like in Java, for example).
Re: MultiThreading in vb6
VB6 does not support true multithreading.
For that, you would need to move to VB.NET
Re: MultiThreading in vb6
The only way I was ever to even come close to multi-threading in VB6 was to create a seperate application for each thread I needed to run. Of course I had to know ahead of time how many seperate threads I needed and in the main VB application launch these when called for. They communicated with each other via DDE. Quite crude and yielded many problems which I had to work out and in the end I figured it just wasn't worth it. Oh, it worked alright but didn't really match up to what you would expect in a true multi-threading application.
Re: MultiThreading in vb6
Wokawidget has a CodeBank entry that "simulates" multithreading. It is about a close as you are going to get with VB6.
Re: MultiThreading in vb6
I didn't know anything about Wokawidget back then when I did what I did and I still don't know what it is.
Re: MultiThreading in vb6
A Wokawidget is one of our members, and a member of the Mod team. :)
Re: MultiThreading in vb6
LOL! OK, I thought it was a thingamagig. I'll see if I can find his stuff. Thanks
Re: MultiThreading in vb6
Re: MultiThreading in vb6
I've always used this and found it to be very stable across many Windows platforms:
http://pscode.com/vb/scripts/ShowCod...26900&lngWId=1
Re: MultiThreading in vb6
A way is to use the BackgroundWorker facilties of .NET and build a wrapper that can be called from VB6. There's a step by step guide here: http://msdn2.microsoft.com/en-us/library/aa719109.aspx
Of course you have to have one of the .NET compilers to make it and the NET 2 Framework. I used VB2005 Express edition (free to download and use) and it all worked OK. Not necessarily the "best" method, but once you've created the wrapper it can be reused in other VB apps.
Re: MultiThreading in vb6
Thanks Doogles...I am going through the article that u have mentioned...Let me check it out and revert if suits my requirement...Thanks again