Re: MultiThread arguments... [unresolved]
Should this be posted in C# forum?
Re: MultiThread arguments... [unresolved]
sounds like you need to wrap the delegate up in a class.. check out this article (specifically the user comments at the bottom)
http://www.codeproject.com/cs/thread...932#xx568932xx
Re: MultiThread arguments... [unresolved]
thanks...
I've made a global variable to temporary fix the situation but I'll look it up... :wave:
Re: MultiThread arguments... [unresolved]
Quote:
Originally Posted by Ruku
thanks...
I've made a global variable to temporary fix the situation but I'll look it up... :wave:
That may not be thread safe to use a global. Let me know how you make out.
Re: MultiThread arguments...
If you're using C# 2005 then you can use a ParameterizedThreadStart delegate instead, which allows you to pass a single Object to the method acting as the thread entry point. That object can be as simple or as complex as you like, so you can pass as much data with as you like.
Re: MultiThread arguments...
John, just to clarify that statement for anyone else who may come across this thread, you mean if you are using .NET 2005, then you can use the ParameterizedThreadStart as it is new to the 2.0 framework.
When I first read it, I thought you meant it was one of those C# but not VB type things. Then I looked it up on MSDN to confirm.
That MSDN sure is great documentation ;)
Re: MultiThread arguments...
everything's fixed, thanks a bunch to all. :wave: