<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Switch activity</title><link>http://blogs.msdn.com/tomlake/archive/2006/08/30/Switch-activity.aspx</link><description>The Switch activity I created is based on the switch statement in C# or the Select Case statements in VB . You have an expression and one or more case statements, one of which can be the default. To model within workflow the case becomes a property that</description><dc:language>en</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: Switch activity</title><link>http://blogs.msdn.com/tomlake/archive/2006/08/30/Switch-activity.aspx#765751</link><pubDate>Fri, 22 Sep 2006 09:26:07 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:765751</guid><dc:creator>serge luca</dc:creator><description>hi Tom, &lt;BR&gt;&lt;BR&gt;this is a very interesting sample ! I learned a lot of stuff. &lt;BR&gt;&lt;BR&gt;May I suggest a small improvement : &lt;BR&gt;&lt;BR&gt;1° if you want the case values to be stored only in arrays &amp;nbsp; you can throw an exception in the Intialize(...) method; it makes sense to make arrays mandatory in a swicth. &lt;BR&gt;&lt;BR&gt;2°if you accept non arrays, then I guess you can modify your Execute method like this: &lt;BR&gt;&lt;BR&gt;if (objs.GetType().IsArray) &lt;BR&gt;{ &lt;BR&gt;... &lt;BR&gt;} &lt;BR&gt;else //provide this small modification &lt;BR&gt;{ &lt;BR&gt;runIt = ((i == (childCount - 1) &amp;amp;&amp;amp; casesValues == null) || casesValues.Equals(switchAct.Expression)); &lt;BR&gt;} &lt;BR&gt;&lt;BR&gt;&lt;BR&gt;Serge Luca &lt;BR&gt;luca@guidance.be &lt;BR&gt;Guidance, Belgium &lt;BR&gt;blog: www.redwood.be</description></item><item><title>re: Switch activity</title><link>http://blogs.msdn.com/tomlake/archive/2006/08/30/Switch-activity.aspx#781000</link><pubDate>Mon, 02 Oct 2006 19:41:21 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:781000</guid><dc:creator>tomlake</dc:creator><description>&lt;p&gt;Thank you Serge for pointing out my code cleanup error. &amp;nbsp;The Cases property should be able to be an object or an array of objects. &amp;nbsp;I have updated the sample.&lt;/p&gt;
</description></item><item><title>Aprendiendo Windows Workflow Foundation</title><link>http://blogs.msdn.com/tomlake/archive/2006/08/30/Switch-activity.aspx#807640</link><pubDate>Mon, 09 Oct 2006 12:50:46 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:807640</guid><dc:creator>Angel "Java" Lopez</dc:creator><description>&lt;p&gt;En estos dias, he ordenado algunos enlaces y recursos sobre el Windows Workflow Foundation, el motor&lt;/p&gt;
</description></item><item><title>re: Switch activity</title><link>http://blogs.msdn.com/tomlake/archive/2006/08/30/Switch-activity.aspx#7470557</link><pubDate>Tue, 05 Feb 2008 20:15:56 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:7470557</guid><dc:creator>igormoochnick</dc:creator><description>&lt;p&gt;Tom, I've implemented the similar attached dependency property but can't make it serialize to and from XOML correctly. Any ideas why is it not hapenning?&lt;/p&gt;
</description></item></channel></rss>