<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments for valerio.net</title>
	<atom:link href="http://thevalerios.net/matt/comments/feed/" rel="self" type="application/rss+xml" />
	<link>http://thevalerios.net/matt</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Wed, 01 Feb 2012 20:01:29 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
	<item>
		<title>Comment on ThreadPool.QueueUserWorkItem With Multiple Arguments by Shaun Bowe</title>
		<link>http://thevalerios.net/matt/2008/06/threadpoolqueueuserworkitem-with-multiple-arguments/comment-page-1/#comment-77527</link>
		<dc:creator>Shaun Bowe</dc:creator>
		<pubDate>Wed, 01 Feb 2012 20:01:29 +0000</pubDate>
		<guid isPermaLink="false">http://thevalerios.net/matt/2008/06/threadpoolqueueuserworkitem-with-multiple-arguments/#comment-77527</guid>
		<description>Nice work!</description>
		<content:encoded><![CDATA[<p>Nice work!</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on A Queued BackgroundWorker Using Generic Delegates by steve</title>
		<link>http://thevalerios.net/matt/2008/05/a-queued-backgroundworker/comment-page-1/#comment-74427</link>
		<dc:creator>steve</dc:creator>
		<pubDate>Mon, 19 Dec 2011 23:54:15 +0000</pubDate>
		<guid isPermaLink="false">http://thevalerios.net/matt/?p=27#comment-74427</guid>
		<description>Thanks for this article.  I have a question. I would like to pass a function that takes in parameter, but in the argument line it doesn&#039;t allow you to pass parameter as it is a Action of T Implementation. I need my argument to be readily available so when the worker get to my item function it knows the object.  How would i do that?</description>
		<content:encoded><![CDATA[<p>Thanks for this article.  I have a question. I would like to pass a function that takes in parameter, but in the argument line it doesn&#8217;t allow you to pass parameter as it is a Action of T Implementation. I need my argument to be readily available so when the worker get to my item function it knows the object.  How would i do that?</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on A Queued BackgroundWorker Using Generic Delegates by Nanda</title>
		<link>http://thevalerios.net/matt/2008/05/a-queued-backgroundworker/comment-page-1/#comment-73324</link>
		<dc:creator>Nanda</dc:creator>
		<pubDate>Wed, 07 Dec 2011 14:32:24 +0000</pubDate>
		<guid isPermaLink="false">http://thevalerios.net/matt/?p=27#comment-73324</guid>
		<description>Hi,

Good article, I tried to reproduce this with ReportProgress too, but getting cross-thread exception (InvalidOperationException), can you update with a ReportProgress option too please?

Thanks,
Nanda</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>Good article, I tried to reproduce this with ReportProgress too, but getting cross-thread exception (InvalidOperationException), can you update with a ReportProgress option too please?</p>
<p>Thanks,<br />
Nanda</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Use ThreadPool.QueueUserWorkItem With Anonymous Types by Iskren Ivanov</title>
		<link>http://thevalerios.net/matt/2008/05/use-threadpoolqueueuserworkitem-with-anonymous-types/comment-page-1/#comment-71412</link>
		<dc:creator>Iskren Ivanov</dc:creator>
		<pubDate>Fri, 25 Nov 2011 10:09:22 +0000</pubDate>
		<guid isPermaLink="false">http://thevalerios.net/matt/?p=14#comment-71412</guid>
		<description>Instead your own InputData class, you can simply use arrays.</description>
		<content:encoded><![CDATA[<p>Instead your own InputData class, you can simply use arrays.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Recursion in F# and the Tail Recursion Police by Using a DataReader like a List in F#</title>
		<link>http://thevalerios.net/matt/2009/01/recursion-in-f-and-the-tail-recursion-police/comment-page-1/#comment-64377</link>
		<dc:creator>Using a DataReader like a List in F#</dc:creator>
		<pubDate>Sat, 08 Oct 2011 00:21:23 +0000</pubDate>
		<guid isPermaLink="false">http://thevalerios.net/matt/2009/01/recursion-in-f-and-the-tail-recursion-police/#comment-64377</guid>
		<description>[...] not making a tail call. F# uses a technique called Tail Call Optimization (TCO, explained here, here and here) to make code run more efficiently. Basically, what that does is take a recursive function [...]</description>
		<content:encoded><![CDATA[<p>[...] not making a tail call. F# uses a technique called Tail Call Optimization (TCO, explained here, here and here) to make code run more efficiently. Basically, what that does is take a recursive function [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Use ThreadPool.QueueUserWorkItem With Anonymous Types by flippster</title>
		<link>http://thevalerios.net/matt/2008/05/use-threadpoolqueueuserworkitem-with-anonymous-types/comment-page-1/#comment-62581</link>
		<dc:creator>flippster</dc:creator>
		<pubDate>Wed, 21 Sep 2011 14:09:42 +0000</pubDate>
		<guid isPermaLink="false">http://thevalerios.net/matt/?p=14#comment-62581</guid>
		<description>This is a very nice article. I just wanted to point out that you could also use reflection to get at your type information from within the thread

var blah = new { One = &quot;heheh&quot;, Two= 1234 };

ThreadPool.QueueUserWorkItem(new WaitCallback(ThreadFire), blah);

static void ThreadFire(object objInput)
{
	Lets use reflection
	Type t = objInput.GetType();

	// Get OPC Client property
	PropertyInfo p1 = t.GetProperty(&quot;One&quot;);
	var one_ = (string)p1.GetValue(objInput, null);

	// Get Tag Name property
	PropertyInfo p2 = t.GetProperty(&quot;Two&quot;);
	var tagName = (int)p2.GetValue(objInput, null);
}</description>
		<content:encoded><![CDATA[<p>This is a very nice article. I just wanted to point out that you could also use reflection to get at your type information from within the thread</p>
<p>var blah = new { One = &#8220;heheh&#8221;, Two= 1234 };</p>
<p>ThreadPool.QueueUserWorkItem(new WaitCallback(ThreadFire), blah);</p>
<p>static void ThreadFire(object objInput)<br />
{<br />
	Lets use reflection<br />
	Type t = objInput.GetType();</p>
<p>	// Get OPC Client property<br />
	PropertyInfo p1 = t.GetProperty(&#8220;One&#8221;);<br />
	var one_ = (string)p1.GetValue(objInput, null);</p>
<p>	// Get Tag Name property<br />
	PropertyInfo p2 = t.GetProperty(&#8220;Two&#8221;);<br />
	var tagName = (int)p2.GetValue(objInput, null);<br />
}</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Use ThreadPool.QueueUserWorkItem With Anonymous Types by flippster</title>
		<link>http://thevalerios.net/matt/2008/05/use-threadpoolqueueuserworkitem-with-anonymous-types/comment-page-1/#comment-62580</link>
		<dc:creator>flippster</dc:creator>
		<pubDate>Wed, 21 Sep 2011 14:08:58 +0000</pubDate>
		<guid isPermaLink="false">http://thevalerios.net/matt/?p=14#comment-62580</guid>
		<description>var blah = new { One = &quot;heheh&quot;, Two= 1234 };

ThreadPool.QueueUserWorkItem(new WaitCallback(ThreadFire), blah);

static void ThreadFire(object objInput)
{
	Lets use reflection
	Type t = objInput.GetType();

	// Get OPC Client property
	PropertyInfo p1 = t.GetProperty(&quot;One&quot;);
	var one_ = (string)p1.GetValue(objInput, null);

	// Get Tag Name property
	PropertyInfo p2 = t.GetProperty(&quot;Two&quot;);
	var tagName = (int)p2.GetValue(objInput, null);
}</description>
		<content:encoded><![CDATA[<p>var blah = new { One = &#8220;heheh&#8221;, Two= 1234 };</p>
<p>ThreadPool.QueueUserWorkItem(new WaitCallback(ThreadFire), blah);</p>
<p>static void ThreadFire(object objInput)<br />
{<br />
	Lets use reflection<br />
	Type t = objInput.GetType();</p>
<p>	// Get OPC Client property<br />
	PropertyInfo p1 = t.GetProperty(&#8220;One&#8221;);<br />
	var one_ = (string)p1.GetValue(objInput, null);</p>
<p>	// Get Tag Name property<br />
	PropertyInfo p2 = t.GetProperty(&#8220;Two&#8221;);<br />
	var tagName = (int)p2.GetValue(objInput, null);<br />
}</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on A Queued BackgroundWorker Using Generic Delegates by Target-Tracking with the Kinect, Part 3 &#8211; Target Tracking Improved, and Speech Recognition &#171; Mark Gilbert&#8217;s Blog</title>
		<link>http://thevalerios.net/matt/2008/05/a-queued-backgroundworker/comment-page-1/#comment-61459</link>
		<dc:creator>Target-Tracking with the Kinect, Part 3 &#8211; Target Tracking Improved, and Speech Recognition &#171; Mark Gilbert&#8217;s Blog</dc:creator>
		<pubDate>Sun, 11 Sep 2011 03:36:02 +0000</pubDate>
		<guid isPermaLink="false">http://thevalerios.net/matt/?p=27#comment-61459</guid>
		<description>[...] What I found was an unbelievably perfect solution from Matt Valerio with his post titled &quot;A Queued BackgroundWorker Using Generic Delegates&quot;.&#160; As the title suggests, he wrote a class called “QueuedBackgroundWorker” that would add [...]</description>
		<content:encoded><![CDATA[<p>[...] What I found was an unbelievably perfect solution from Matt Valerio with his post titled &quot;A Queued BackgroundWorker Using Generic Delegates&quot;.&#160; As the title suggests, he wrote a class called “QueuedBackgroundWorker” that would add [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Use ThreadPool.QueueUserWorkItem With Anonymous Types by pepepaco</title>
		<link>http://thevalerios.net/matt/2008/05/use-threadpoolqueueuserworkitem-with-anonymous-types/comment-page-1/#comment-58942</link>
		<dc:creator>pepepaco</dc:creator>
		<pubDate>Thu, 18 Aug 2011 23:21:38 +0000</pubDate>
		<guid isPermaLink="false">http://thevalerios.net/matt/?p=14#comment-58942</guid>
		<description>the easiest way to notify the main thread is to pass an Action parmeter along with the data parameters besides the Action to be executed. for example:

ThreadPoolHelper.QueueUserWorkItem(
    new { Name = &quot;Matt&quot;, Age = 26, CallbackWhendone = ExecWhendone },
    (data) =&gt;
    {
        string name = data.Name;
        int age = data.Age;        
        // Long-running computation
        data.CallbackWhendone();
    });

//where ExecWhendone is the method to be called when the calculation is done.(I have not tested it)</description>
		<content:encoded><![CDATA[<p>the easiest way to notify the main thread is to pass an Action parmeter along with the data parameters besides the Action to be executed. for example:</p>
<p>ThreadPoolHelper.QueueUserWorkItem(<br />
    new { Name = &#8220;Matt&#8221;, Age = 26, CallbackWhendone = ExecWhendone },<br />
    (data) =&gt;<br />
    {<br />
        string name = data.Name;<br />
        int age = data.Age;<br />
        // Long-running computation<br />
        data.CallbackWhendone();<br />
    });</p>
<p>//where ExecWhendone is the method to be called when the calculation is done.(I have not tested it)</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on ThreadPool.QueueUserWorkItem With Multiple Arguments by Khayralla</title>
		<link>http://thevalerios.net/matt/2008/06/threadpoolqueueuserworkitem-with-multiple-arguments/comment-page-1/#comment-47908</link>
		<dc:creator>Khayralla</dc:creator>
		<pubDate>Tue, 10 May 2011 16:19:39 +0000</pubDate>
		<guid isPermaLink="false">http://thevalerios.net/matt/2008/06/threadpoolqueueuserworkitem-with-multiple-arguments/#comment-47908</guid>
		<description>Greate job, but Action can take four parameters only.
How can you define QueueUserWorkItem with 5 parameters.
Thank you.</description>
		<content:encoded><![CDATA[<p>Greate job, but Action can take four parameters only.<br />
How can you define QueueUserWorkItem with 5 parameters.<br />
Thank you.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

