Is There any way to share global object variable value inside the Parallel.ForEach ,for example only one task can access it and update it's value at one time during this time other task will wait and so on.
It will be really helpful if i can get some code example.
i check the How to: Write a Parallel.For Loop with Thread-Local Variables but i am looking the way to share global value among the parallel task.
It will be really helpful if i can get some code example.
i check the How to: Write a Parallel.For Loop with Thread-Local Variables but i am looking the way to share global value among the parallel task.