<?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>Richard Seroter - SoCal BizTalk Musings : Other</title><link>http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx</link><description>Tags: Other</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>I'm Out</title><link>http://blogs.msdn.com/richardbpi/archive/2007/01/11/i-m-out.aspx</link><pubDate>Fri, 12 Jan 2007 01:16:54 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1452362</guid><dc:creator>rseroter</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/1452362.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=1452362</wfw:commentRss><description>&lt;p&gt;&lt;/p&gt; &lt;p&gt;Today's my last day here at Microsoft, and as of now, this blog is locked down.&amp;nbsp; But, my BizTalk party will continue over at &lt;a href="http://seroter.wordpress.com"&gt;http://seroter.wordpress.com&lt;/a&gt;.&amp;nbsp; Thanks to all who have contributed, and see you on the other side.&lt;/p&gt; &lt;p&gt; &lt;div class="wlWriterSmartContent" id="0767317B-992E-4b12-91E0-4F059A8CECA8:765e2be0-d59d-456e-9362-a473a382785f" contenteditable="false" style="padding-right: 0px; display: inline; padding-left: 0px; padding-bottom: 0px; margin: 0px; padding-top: 0px"&gt;Technorati tags: &lt;a href="http://technorati.com/tags/BizTalk" rel="tag"&gt;BizTalk&lt;/a&gt;&lt;/div&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=1452362" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Leaving Microsoft ...</title><link>http://blogs.msdn.com/richardbpi/archive/2007/01/02/leaving-microsoft.aspx</link><pubDate>Wed, 03 Jan 2007 02:52:21 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1400985</guid><dc:creator>rseroter</dc:creator><slash:comments>2</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/1400985.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=1400985</wfw:commentRss><description>&lt;span style="font-size: 10pt; font-family: arial"&gt; &lt;p&gt;Next Thursday, 1/11/07 will be my last day at Microsoft.&amp;nbsp;&amp;nbsp;I've decided to take an "Architect" position with one of my customers in the Los Angeles area.&amp;nbsp; It was a tough choice to leave my great colleagues and customers, but I'm fairly jazzed about the new opportunities I now have.&lt;/p&gt; &lt;p&gt;So, much like &lt;a href="http://en.wikipedia.org/wiki/Han_Solo"&gt;Han Solo&lt;/a&gt;&amp;nbsp;in &lt;a href="http://www.imdb.com/title/tt0080684/"&gt;The Empire Strikes Back&lt;/a&gt;, this particular&amp;nbsp;blog will be frozen.&amp;nbsp; Next week it will get locked from any future usage.&amp;nbsp; My new employer has indicated support for my blogging habit, so, I've set up a new blog at &lt;a href="http://seroter.wordpress.com"&gt;http://seroter.wordpress.com&lt;/a&gt;.&amp;nbsp; I plan on continuing to do the same things on that blog that I do on the current one.&amp;nbsp; So, look out for more code snippets, walkthroughs, demos, reviews, pointers to cool resources and more.&amp;nbsp; I just posted an article on the new &lt;a href="http://seroter.wordpress.com/"&gt;BizTalk blog&lt;/a&gt; about "&lt;a href="http://seroter.wordpress.com/2007/01/02/orchestration-handling-of-suspended-messages/"&gt;considerations for resuming suspended orchestrations&lt;/a&gt;".&amp;nbsp; Thrilling stuff.&lt;/p&gt; &lt;p&gt;I've really appreciated all the great feedback and questions resulting from the 160+ posts on this blog, and hope you'll continue participating in the new one.&lt;/p&gt; &lt;p style="font-size: 10px"&gt;Technorati Tags: &lt;a href="http://technorati.com/tag/BizTalk" rel="tag"&gt;BizTalk&lt;/a&gt; &lt;/p&gt;&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=1400985" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/BizTalk/default.aspx">BizTalk</category><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Back In Town, And Commerce Server Best Practices Analyzer</title><link>http://blogs.msdn.com/richardbpi/archive/2006/09/12/750470.aspx</link><pubDate>Tue, 12 Sep 2006 15:54:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:750470</guid><dc:creator>rseroter</dc:creator><slash:comments>2</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/750470.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=750470</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
Just returned from a pleasant 10-day vacation to London and Edinburgh and am ready to get back to work.  A few musings ...
&lt;ul&gt;
	&lt;li&gt;
	If you live in the LA area, I recommend NOT using &lt;a href="http://www.sedanbylax.com/"&gt;LA Limo Service&lt;/a&gt; for transportation.  I got a call an hour before my pickup saying they had to cancel
	because the driver was in traffic.  Traffic in Southern California ... shocking.  Good planning, Magellan.
	&lt;/li&gt;
	&lt;li&gt;
	Why are there so many freakin' Italian restaurants in London?  I think they outnumbered the English pubs.  Best food I had was actually
	Indian.  Just great stuff at &lt;a href="http://www.mykensington.co.uk/kensington/restaurants-reviews-moti_mahal_restaurant.htm"&gt;Moti Mahal&lt;/a&gt; in Kensington.
	&lt;/li&gt;
	&lt;li&gt;
	For a city that has virtually no pubic trash receptacles, the streets are surprisingly clean.  Where does all the trash go (not counting
	the Tube tracks)?
	&lt;/li&gt;
	&lt;li&gt;
	If you get chance, that train ride from London to Scotland is something else.  You don't get scenery like that in SoCal.
	&lt;/li&gt;
	&lt;li&gt;
	I've developed a man-crush on St. Louis Cardinals baseball coach Tony La Russa after reading &lt;a href="http://www.amazon.com/Three-Nights-August-Strategy-Heartbreak/dp/0618710531/sr=8-2/qid=1158030788/ref=pd_bbs_2/104-1892718-9535966?ie=UTF8&amp;s=books"&gt;
	Three Nights in August&lt;/a&gt; on the plane flight.  Of the couple dozen books I've read this year, this might be my favorite.
	&lt;/li&gt;
	&lt;li&gt;
	If your female companion wants to wear 3-inch heeled boots to tour a hilly, cobblestone saturated castle, take my advice, 
	tell them not to.  It's terrifying to watch.
	&lt;/li&gt;
&lt;/ul&gt;
&lt;/p&gt;
&lt;p&gt;
In order to not make this a completely useless post from a technical perspective, don't forget
to check out the brand new &lt;a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=6be6a088-d613-471a-b1a6-e80dc5050494&amp;displaylang=en"&gt;
Commerce Server 2007 Best Practices Analyzer&lt;/a&gt;.  As with the BizTalk BPA, it doesn't change any configuration settings, but, does
make you aware of less than optimal settings.
&lt;/p&gt;
&lt;p style="font-size:10px"&gt;
Technorati Tags: &lt;a href="http://technorati.com/tag/BizTalk" rel="tag"&gt;Commerce Server&lt;/a&gt;
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=750470" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Commerce+Server/default.aspx">Commerce Server</category><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Compelling Article on Ray Ozzie and Microsoft Strategy</title><link>http://blogs.msdn.com/richardbpi/archive/2006/04/19/579581.aspx</link><pubDate>Thu, 20 Apr 2006 06:24:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:579581</guid><dc:creator>rseroter</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/579581.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=579581</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
Not integration-related from a BizTalk sense, but this &lt;a href="http://money.cnn.com/magazines/fortune/fortune_archive/2006/05/01/8375454/index.htm"&gt;
article in Fortune&lt;/a&gt; about Ray Ozzie and the changes at Microsoft has a lot to 
do with integration of vision and products at this company.
&lt;/p&gt;
&lt;p&gt;
Just a fascinating read, and reassures me that I made the right choice joining Microsoft 12 months ago.
&lt;/p&gt;
&lt;p style="font-size:10px"&gt;
Technorati Tags: &lt;a href="http://technorati.com/tag/Microsoft" rel="tag"&gt;Microsoft&lt;/a&gt;
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=579581" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Virtual Server 2005 R2 Now Free (And Supporting Linux)</title><link>http://blogs.msdn.com/richardbpi/archive/2006/04/03/567397.aspx</link><pubDate>Mon, 03 Apr 2006 19:55:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:567397</guid><dc:creator>rseroter</dc:creator><slash:comments>2</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/567397.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=567397</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
Nice!  We announced today (see 
&lt;a href="http://www.microsoft.com/windowsserversystem/virtualserver/software/default.mspx"&gt;HERE&lt;/a&gt; and 
&lt;a href="http://www.microsoft.com/presspass/features/2006/apr06/04-03virtualizationqa.mspx"&gt;HERE&lt;/a&gt; and
&lt;a href="http://news.com.com/Microsoft+to+host+Linux+virtually/2100-7346_3-6056683.html?tag=nefd.top"&gt;HERE&lt;/a&gt;) that Virtual 
Server 2005 R2 is a &lt;b&gt;free download&lt;/b&gt;, and, will host Linux.  I'm preparing
some materials for an upcoming 5-day lab for SoCal customers, and we'll be building a BizTalk Server farm in Virtual Server.
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=567397" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Windows Workflow in ASP.NET Apps</title><link>http://blogs.msdn.com/richardbpi/archive/2006/03/19/555129.aspx</link><pubDate>Mon, 20 Mar 2006 00:02:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:555129</guid><dc:creator>rseroter</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/555129.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=555129</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
Very very nice article in this month's MSDN Magazine that goes into great depth explaining how to use &lt;a href="http://msdn.microsoft.com/msdnmag/issues/06/04/CuttingEdge/default.aspx"&gt;
Windows Workflow from an ASP.NET application 
(or service)&lt;/a&gt;.  I may have to re-jigger my &lt;a HREF="/richardbpi/archive/2006/02/17/534406.aspx"&gt;Sharepoint-WF-BizTalk post&lt;/a&gt; from a few weeks back using this updated info.
&lt;/p&gt;
&lt;p&gt;
Also, from the same MSDN issue, see &lt;a href="http://msdn.microsoft.com/msdnmag/issues/06/04/EditorsNote/default.aspx"&gt;some props&lt;/a&gt; to 
my man &lt;a href="http://www.geekswithblogs.net/sthomas/"&gt;Stephen Thomas&lt;/a&gt; for his great BizTalk entry to the Connected Systems Developer competition.  Nicely done.
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=555129" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/BizTalk/default.aspx">BizTalk</category><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Using Business Rules Engine "Update" for Forward Chaining</title><link>http://blogs.msdn.com/richardbpi/archive/2006/03/13/550788.aspx</link><pubDate>Tue, 14 Mar 2006 01:19:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:550788</guid><dc:creator>rseroter</dc:creator><slash:comments>3</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/550788.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=550788</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
Fitting that my 100th post is on the same topic as &lt;a HREF="/richardbpi/archive/2005/06/09/427361.aspx"&gt;one of my first&lt;/a&gt;, the Business Rules Engine.
&lt;/p&gt;
&lt;p&gt;
The other day I had a customer ask me about a problem they had while executing a business rule on a repeating element where the result
was not what they expected.  The scenario consisted of multiple address nodes with an element called &lt;b&gt;OptOutDays&lt;/b&gt;.  The role of the business rule
was to evaluate each &lt;b&gt;Address/OptOutDays&lt;/b&gt; and store the largest one in a root-level field called &lt;b&gt;TempOptOutDays&lt;/b&gt;.  
For instance, I have an XML input instance (see below) that has three address lines, and &lt;b&gt;OptOutDays&lt;/b&gt; of 170, 120, and 100.  So the rule action had to update
the &lt;b&gt;TempOptOutDays&lt;/b&gt; with the max amount, in this case, 170.&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/03.13.2006rule1.jpg" &gt;
&lt;/p&gt;
&lt;p&gt;
The problem was that this customer's &lt;b&gt;TempOptOutDays&lt;/b&gt; value didn't contain highest &lt;b&gt;OptOutDays&lt;/b&gt; amount.  So I spent some time rebuilding their scenario, and discovered
that because they had not properly set up forward-chaining, the &lt;b&gt;TempOptOutDays&lt;/b&gt; value was getting overwritten by each looping pass.
I wrote the rule you see in the picture below.  Note that I use an &lt;b&gt;Update&lt;/b&gt; action step so that I am telling the Business Rules Engine to
reevaluate the particular fact.  In this case I'm passing in the parent element of the &lt;b&gt;TempOptOutDays&lt;/b&gt; node, which is the root element.
&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/03.13.2006rule2.jpg" &gt;
&lt;/p&gt;
&lt;p&gt;
So why did that matter?  The BRE goes through three stages when executing policies: matching, conflict resolution and action.  During the matching phase,
the execution agenda is populated by rules that match the conditions and input facts.  During this particular matching instance, the BRE adds this rule to the agenda for 
each "address" fact, since the default &lt;b&gt;TempOptOutDays&lt;/b&gt; is 0, and each rule condition should fire (see picture below).  It does NOT take into account that the rule's action 
CHANGES that &lt;b&gt;TempOptOutDays&lt;/b&gt; value from pass to pass, and therefore overwrites the value each time (treating it as 0).  So, the &lt;b&gt;Update&lt;/b&gt; forces the BRE 
to intelligently reevaluate the rules and therefore always consider the CURRENT value of &lt;b&gt;TempOptOutDays&lt;/b&gt; element.
&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/03.13.2006rule3.jpg" &gt;
&lt;/p&gt;
&lt;p&gt;
I rewrote this a couple times, and it still reads back a bit confusing.  But the moral of the story is, if you have forward-chaining scenarios, think 
about how to efficiently update the facts in memory when the values of those facts drive other rules.
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=550788" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/BizTalk/default.aspx">BizTalk</category><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Microsoft RFID Platform Offering Explained</title><link>http://blogs.msdn.com/richardbpi/archive/2006/02/26/539632.aspx</link><pubDate>Mon, 27 Feb 2006 05:01:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:539632</guid><dc:creator>rseroter</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/539632.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=539632</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
We just published a paper on the upcoming &lt;a href="http://www.microsoft.com/biztalk/2006/prodinfo/rfid.mspx"&gt;Microsoft RFID&lt;/a&gt; offering, and it's 
actually fairly informative.  It covers the basic background, ideal applications, issues with current solutions, and finally a dive into our
platform (which is currently in beta) and how it adds value.  Check out how BizTalk can play such a key role in the stack here.
&lt;/p&gt;
&lt;p&gt;
On another note, I'll be abusing a new crop of customers in a 5-day BizTalk hands-on exercise I'm delivering this week from our fancy new LA office.
Those possessing substandard concentration skills may simply stare at the &lt;a href="http://search.msn.com/images/results.aspx?FORM=IRRE&amp;q=hollywood%20sign"&gt;
Hollywood sign&lt;/a&gt; which is visible from the training room.  I should hopefully be pump out an interesting post or two during nap time.
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=539632" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/BizTalk/default.aspx">BizTalk</category><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Windows Workflow + SharePoint 2003 + BizTalk Scenario Built Out</title><link>http://blogs.msdn.com/richardbpi/archive/2006/02/17/534406.aspx</link><pubDate>Sat, 18 Feb 2006 00:29:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:534406</guid><dc:creator>rseroter</dc:creator><slash:comments>9</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/534406.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=534406</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
So I had a use case from a customer to build a sample using BizTalk Server, Windows Workflow Foundation, and Windows SharePoint Services 2003.  It was
an interesting journey, and wanted to show how I got all these pieces to play nicely.
&lt;/p&gt;
&lt;p&gt;
Before diving into each technical component, here's a summary of the use case.
&lt;ol&gt;
	&lt;li&gt;Purchase Order document received from ERP system.&lt;/li&gt;
	&lt;li&gt;BizTalk looks at the document, assigns a reviewer, and publishes it to SharePoint.&lt;/li&gt;
	&lt;li&gt;SharePoint kicks off a workflow which creates a &lt;b&gt;Task&lt;/b&gt; item for that user, and potentially sends them an email.&lt;/li&gt;
	&lt;li&gt;User loads up PO, and approves it.&lt;/li&gt;
	&lt;li&gt;SharePoint again triggers workflow which then marks users &lt;b&gt;Task&lt;/b&gt; as "complete."&lt;/li&gt;
&lt;/ol&gt;
&lt;/p&gt;
&lt;p&gt;
Now as you may know, the next version of SharePoint (I think called SharePoint 2007) will have Windows Workflow integrated.  But for now, it doesn't.  So
there are multiple components that I put together to make this work.
&lt;/p&gt;
&lt;p&gt;
&lt;b&gt;Component: SharePoint Doc Library Configuration&lt;/b&gt;&lt;br&gt;&lt;br&gt;
First things first, I had to create the SharePoint document library.  I did this by creating a BizTalk XSD schema, then creating an InfoPath form
that used it, and finally publishing that InfoPath form to my SharePoint site, thus generating the library with an associated template.  Once I had
the library, I had to view the &lt;b&gt;Change Advanced Settings&lt;/b&gt; page under &lt;b&gt;Modify Columns and Settings&lt;/b&gt;.  From here, I can define an event 
handler which will fire whenever a change is made to the SharePoint library.  So, once I have it built, I'll reference my Event Handler class here.
&lt;/p&gt;
&lt;p&gt;
&lt;b&gt;Component: SharePoint Event Handler&lt;/b&gt;&lt;br&gt;&lt;br&gt;
This one was fun.  I created a class that referenced the &lt;b&gt;Microsoft.SharePoint&lt;/b&gt; assembly and implemented the &lt;b&gt;IListEventSink&lt;/b&gt; interface.  It also
references the &lt;b&gt;System.Workflow.Runtime&lt;/b&gt; assembly.  The &lt;b&gt;OnEvent&lt;/b&gt; method accepts a parameter of type &lt;b&gt;SPListEvent&lt;/b&gt;.  This is great since
that object contains all sorts of info about the document and library that spawned the event.  My first decision in this method is to determine
which event just fired:&lt;br&gt;
&lt;span style="font-family:Courier"&gt;if (listEvent.Type == SPListEventType.Insert || listEvent.Type == SPListEventType.Update)&lt;/span&gt;&lt;br&gt;&lt;br&gt;
 Then I created an instance of the &lt;b&gt;WorkflowRuntime&lt;/b&gt; object that will execute the workflow. Since a workflow can accept any sort of parameter in,
 I fill the input dictionary with the SharePoint event  (SPListEvent) and a string indicating whether an &lt;b&gt;Insert&lt;/b&gt; or &lt;b&gt;Update&lt;/b&gt; has occurred. 
 Finally, I stop the runtime when the Workflow has completed.  Now, after throwing the assembly in the GAC, I can go back to SharePoint and add my
 Event Handler class.&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/02.17.2006wf1.jpg" &gt;
&lt;/p&gt;
&lt;p&gt;
&lt;b&gt;Component: Windows Workflow&lt;/b&gt;&lt;br&gt;&lt;br&gt;
My workflow looks like this:&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/02.17.2006wf2.jpg" &gt;
&lt;br&gt;&lt;br&gt;
This class references the core SharePoint library again so that I can interact with the site. My first workflow shape simply initiates all my member 
variables that are used by later steps.  For instance, I have a member variable that is a pointer to my SharePoint site.  I just took the SPListEvent
that came into my workflow and used its &lt;b&gt;Site&lt;/b&gt; member to gain my reference:&lt;br&gt;
 &lt;span style="font-family:Courier"&gt;activeSite = currentSPEvent.Site.OpenWeb();&lt;/span&gt;&lt;br&gt;&lt;br&gt;
 Then I went about setting all sorts of variables for sending email, and so forth.  One tricky thing to be aware of.  So when I created my SharePoint document
 library via InfoPath, I promoted a number of columns.  Now, those values are available to me in the SPListEvent object.  &lt;b&gt;However&lt;/b&gt;, the names of the
 columns don't come through, but rather, a GUID.  That mapping between the name of the promoted column and the GUID identifier is stored in the SharePoint
 library's &lt;b&gt;Forms&lt;/b&gt; folder in the &lt;b&gt;properties.xfp&lt;/b&gt; file.  So, I just grabbed the GUID for the column I wanted and set my variable as such:&lt;br&gt;
 &lt;span style="font-family:Courier"&gt;taskStatus = Convert.ToString(currentSPEvent.PropertiesAfter["xd_{5264C7A5-9142-488F-923B-0721E8770775}"]);&lt;/span&gt;&lt;br&gt;&lt;br&gt;
 Got that?&lt;br&gt;&lt;br&gt;
 The next shape that fires (assuming an &lt;b&gt;Insert&lt;/b&gt; operation) is the &lt;b&gt;CreateTask&lt;/b&gt; action.  The code is fairly simple and looks like this:&lt;br&gt;
 &lt;span style="font-family:Courier"&gt;

 SPListItemCollection listItems = activeSite.Lists[taskListName].Items;&lt;br&gt;
SPListItem wfTask = listItems.Add();&lt;br&gt;&lt;br&gt;

//set task values&lt;br&gt;
wfTask["ReqID"] = reqID;&lt;br&gt;
 wfTask["Title"] = taskTitle;&lt;br&gt;
 wfTask["Assigned To"] = activeSite.Users[@taskAssignment];&lt;br&gt;
wfTask["Status"] = taskStatus;&lt;br&gt;
 wfTask["Start Date"] = DateTime.Now;&lt;br&gt;&lt;br&gt;

//insert task into collection&lt;br&gt;
wfTask.Update();
 &lt;/span&gt;&lt;br&gt;&lt;br&gt;
 For the &lt;b&gt;SendMail&lt;/b&gt; shape, I simply utilize the &lt;b&gt;System.Net.Mail&lt;/b&gt; assembly to build out a simple mail message.  If an update is occuring, I need
 to see if the status is &lt;b&gt;Complete&lt;/b&gt;, and if so, mark the appropriate SharePoint task as &lt;b&gt;Complete&lt;/b&gt;.  So if the task is &lt;b&gt;Complete&lt;/b&gt; I use the 
 &lt;b&gt;SPQuery&lt;/b&gt; object to build a query that only returns the task with the corresponding &lt;b&gt;ReqID&lt;/b&gt; value, then update that task.&lt;br&gt;
  &lt;span style="font-family:Courier"&gt;
 //build query to pull back task with specific ReqID&lt;br&gt;
SPQuery itemQuery = new SPQuery();&lt;br&gt;
itemQuery.Query = "&amp;lt;Where&amp;gt;&amp;lt;Eq&amp;gt;&amp;lt;FieldRef Name='ReqID'&amp;gt;&amp;lt;/FieldRef&amp;gt;&amp;lt;Value Type='Text'&amp;gt;" + reqID + "&amp;lt;/Value&amp;gt;&amp;lt;/Eq&amp;gt;&amp;lt;/Where&amp;gt;";&lt;br&gt;&lt;br&gt;

SPList taskList = activeSite.Lists[taskListName];&lt;br&gt;
SPListItemCollection taskListItems = taskList.GetItems(itemQuery);&lt;br&gt;&lt;br&gt;

//if task still exists ...&lt;br&gt;
if (taskListItems.Count &gt; 0)&lt;br&gt;
 {&lt;br&gt;
//set status to completed&lt;br&gt;
SPListItem wfTask = taskListItems[0];&lt;br&gt;
wfTask["Status"] = "Completed";&lt;br&gt;&lt;br&gt;

try&lt;br&gt;
{&lt;br&gt;
wfTask.Update();&lt;br&gt;

System.Diagnostics.EventLog.WriteEntry("WF", "Task Updated");&lt;br&gt;
}&lt;br&gt;
catch (Exception ex)&lt;br&gt;
{&lt;br&gt;
System.Diagnostics.EventLog.WriteEntry("WF", ex.ToString());&lt;br&gt;
}&lt;br&gt;
&lt;/span&gt;&lt;br&gt;&lt;br&gt;
And that's pretty much the workflow piece.
&lt;/p&gt;
&lt;p&gt;
&lt;b&gt;Component: BizTalk Server&lt;/b&gt;&lt;br&gt;&lt;br&gt;
My BizTalk piece right now is fairly brain-dead.  Just picks up a file, sends it to the SharePoint library, thus triggering the workflow.
&lt;/p&gt;
&lt;p&gt;
&lt;b&gt;Final solution&lt;/b&gt;&lt;br&gt;&lt;br&gt;
So what does this look like right now?  A file gets put in my SharePoint library ...&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/02.17.2006wf3.jpg" &gt;
&lt;br&gt;&lt;br&gt;
Then, a task is created ...&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/02.17.2006wf4.jpg" &gt;
&lt;br&gt;&lt;br&gt;
Next an email is sent ... &lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/02.17.2006wf5.jpg" &gt;
&lt;br&gt;&lt;br&gt;
User changes the doc, and saves it, and the Task gets updated to &lt;b&gt;Complete&lt;/b&gt; ... &lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/02.17.2006wf6.jpg" &gt;
&lt;br&gt;&lt;br&gt;
&lt;/p&gt;
&lt;p&gt;
&lt;b&gt;Gotchas&lt;/b&gt;&lt;br&gt;&lt;br&gt;
I glossed over a few things that were indeed comically tricky.  So, here are a few notes, and links that helped me out ...
&lt;ul&gt;
&lt;li&gt;SharePoint site that hosts the document library must be running under ASP.NET 2.0&lt;/li&gt;
&lt;li&gt;Only a single workflow runtime can be loaded in the App Domain at one time.  So, I'll have modify my process for starting workflow instances
in order to handle parallel load.&lt;/li&gt;
&lt;li&gt;Had to incorporate some impersonation in order to get the Workflow the necessary permissions to interact with SharePoint.  Used the 
&lt;b&gt;WindowsImpersonationContext&lt;/b&gt; object and during variable initialization in the Workflow I started the impersonation, and at the end of the
process I executed the &lt;b&gt;Undo()&lt;/b&gt; method to reset permissions on the thread.&lt;/li&gt;
&lt;li&gt;Absolutely invaluable &lt;a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=AA3E7FE5-DAEE-4D10-980F-789B827967B0&amp;displaylang=en"&gt;SharePoint SDK&lt;/a&gt; for the full SharePoint API.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://msdn.microsoft.com/msdnmag/issues/05/02/RecycleBinforWSS/default.aspx"&gt;MSDN article demonstrating some SharePoint eventing&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a HREF="/lamonth/articles/372071.aspx"&gt;Part 1&lt;/a&gt; and &lt;a HREF="/lamonth/articles/372072.aspx"&gt;Part 2&lt;/a&gt; of useful blog series&lt;/li&gt;
&lt;li&gt;Nice, but a bit outdated &lt;a href="http://msdn.microsoft.com/windowsvista/building/workflow/default.aspx?pull=/library/en-us/dnlong/html/wwfgetstart.asp"&gt;Windows Workflow article&lt;/a&gt; on MSDN.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://blogs.iwaszko.com/mark/PermaLink,guid,11f1623b-caa3-4ac0-b326-6df08013a4c6.aspx"&gt;Helpful post on SharePoint events and .NET 2.0&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=534406" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/BizTalk/default.aspx">BizTalk</category><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Nice Free AJAX Library from Yahoo!</title><link>http://blogs.msdn.com/richardbpi/archive/2006/02/15/532566.aspx</link><pubDate>Wed, 15 Feb 2006 18:44:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:532566</guid><dc:creator>rseroter</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/532566.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=532566</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
This has nothing to do with BizTalk, but I'm just really impressed with the new, &lt;a href="http://developer.yahoo.net/yui/"&gt;free collection of AJAX utilities and controls&lt;/a&gt; that Yahoo! just made
available.  Solid utility classes (animation, drag-drop), and nice UI controls (calendar, treeview).  I'm working in my free time on something that could make very good use of this.&lt;br&gt;&lt;br&gt;&lt;br&gt;
Hat Tip: &lt;a href="http://www.larkware.com/dg5/TheDailyGrind820.html"&gt;Daily Grind&lt;/a&gt;
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=532566" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Couples Weeks Off, And Upcoming Topics</title><link>http://blogs.msdn.com/richardbpi/archive/2005/10/07/478326.aspx</link><pubDate>Fri, 07 Oct 2005 21:19:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:478326</guid><dc:creator>rseroter</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/478326.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=478326</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
So I'll be going dark here for a couple weeks as I head off on vacation (getting married, and no live-blogging of the honeymoon).  However,
I've got a few things queued up when I get back, including my experiences building J2EE web services to integrate with BizTalk, how to
build an alternate business-focused Business Rules interface, and more.  So stay tuned.
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=478326" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>Debating Our Rules Engine</title><link>http://blogs.msdn.com/richardbpi/archive/2005/09/17/470644.aspx</link><pubDate>Sat, 17 Sep 2005 22:45:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:470644</guid><dc:creator>rseroter</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/470644.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=470644</wfw:commentRss><description>&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: arial"&gt;
&lt;P&gt;If you're someone deeply interested in rule engine algorithms, and specifically Microsoft's implementation of the Rete algorithm in the Rules Engine that ships with BizTalk Server 2004, then you absolutely must read this &lt;A href="http://geekswithblogs.net/cyoung/articles/54022.aspx"&gt;facinating study by Charles Young&lt;/A&gt;. Charles also talks about some of the background of the &lt;A href="http://geekswithblogs.net/cyoung/archive/2005/09/17/54206.aspx"&gt;debate around our implementation here.&lt;/A&gt; I shake my fist at you, Charles, for forcing me to spend 2 hours on a sunny Saturday reading about rules engines! Such interesting stuff. &lt;/P&gt;&lt;/SPAN&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=470644" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/BizTalk/default.aspx">BizTalk</category><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>PDC05 - Day 1 SQL Service Broker Musings</title><link>http://blogs.msdn.com/richardbpi/archive/2005/09/13/465152.aspx</link><pubDate>Wed, 14 Sep 2005 01:44:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:465152</guid><dc:creator>rseroter</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/465152.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=465152</wfw:commentRss><description>&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: arial"&gt;
&lt;P&gt;Attending the &lt;B&gt;Building Distributed Asynchronous Applications with SQL Service Broker&lt;/B&gt; session at &lt;A href="http://msdn.microsoft.com/events/pdc/"&gt;PDC05&lt;/A&gt; and thought I'd share these notes .... 
&lt;UL&gt;
&lt;LI&gt;Service Broker is for SQL Server applications 
&lt;LI&gt;The &lt;B&gt;queues&lt;/B&gt; are actually database objects 
&lt;LI&gt;You can write these applications as stored procedures with T-SQL (or .NET). New T-SQL keywords include: 
&lt;UL&gt;
&lt;LI&gt;transaction 
&lt;LI&gt;receive 
&lt;LI&gt;conversation 
&lt;LI&gt;waitfor(?) 
&lt;LI&gt;queue 
&lt;LI&gt;xml (as part of SQL Server 2005) &lt;/LI&gt;&lt;/UL&gt;
&lt;LI&gt;Reliable messaging included for queuing across databases 
&lt;LI&gt;&lt;B&gt;Dialogs&lt;/B&gt; are for two-way messaging between services 
&lt;UL&gt;
&lt;LI&gt;Guaranteed delivery, in-order delivery, secure communications 
&lt;LI&gt;Dialogs can be over a long period of time, or short &lt;/LI&gt;&lt;/UL&gt;
&lt;LI&gt;A &lt;B&gt;service&lt;/B&gt; is a named endpoint that a message can travel to 
&lt;LI&gt;Some basic code might start like:&lt;BR&gt;&lt;FONT face=Courier&gt;create queue [Inventory Queue];&lt;BR&gt;create service [Inventory]&lt;BR&gt;on queue [Inventory Queue] ([DEFAULT)];&lt;/FONT&gt; 
&lt;LI&gt;Begin a dialog transaction "from" a service, "to" a service and pass on a defined transaction 
&lt;LI&gt;On target server, you select from the destination queue 
&lt;LI&gt;Can debug the T-SQL service from within Visual Studio.NET 
&lt;LI&gt;What if you don't want all the logic within stored procs? Answer: &lt;B&gt;External Activation&lt;/B&gt; 
&lt;UL&gt;
&lt;LI&gt;Messages placed in an Event Queue where an external activitor handles the logic &lt;/LI&gt;&lt;/UL&gt;
&lt;LI&gt;Visit &lt;A href="http://www.sqlservicebroker.com"&gt;www.sqlservicebroker.com&lt;/A&gt; 
&lt;LI&gt;How do you keep this working without deadlocking? Answer: &lt;B&gt;Conversation Group Locking&lt;/B&gt; 
&lt;UL&gt;
&lt;LI&gt;Dialogs are single-threaded 
&lt;LI&gt;Locking of conversations to prevent collisions [note: look at further] &lt;/LI&gt;&lt;/UL&gt;
&lt;LI&gt;Announcing ... &lt;B&gt;Indigo (WCF)&lt;/B&gt; channel for the Service Broker! 
&lt;LI&gt;Using (datbase stored) certificates and public/private keys for Dialog Security between service endpoints 
&lt;LI&gt;Summary: Asynchronous DB "Stuff", Reliable Messaging, Reliable SOA &lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;/P&gt;&lt;/SPAN&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=465152" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category><category domain="http://blogs.msdn.com/richardbpi/archive/tags/PDC05/default.aspx">PDC05</category></item><item><title>End To End Email WIth BizTalk On A Single Dev Box</title><link>http://blogs.msdn.com/richardbpi/archive/2005/08/30/458088.aspx</link><pubDate>Tue, 30 Aug 2005 22:15:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:458088</guid><dc:creator>rseroter</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/458088.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=458088</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
Often for either isolated BizTalk development or BizTalk demonstration purposes, the need arises to do a full email scenario on a single physical 
or virtual machine.  Did you know that you can utilize the standard Windows Server 2003 plug-in SMTP and POP3 services to send a receive 
email on a single box without installing a full email server?
&lt;/p&gt;
&lt;p&gt;
You're probably familiar with the SMTP service you can install as part of IIS. Once installed, it looks like this ... &lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/8.30.2005FullEmail1.jpg" &gt;
&lt;br&gt;&lt;br&gt;
&lt;/p&gt;
&lt;p&gt;
Now you can also install the basic POP3 service included in Windows Server 2003.  In the &lt;b&gt;Add or Remove Programs&lt;/b&gt; it's under
&lt;b&gt;Add/Remove Windows Components&lt;/b&gt; and labeled &lt;b&gt;Email Services.&lt;/b&gt;&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/8.30.2005FullEmail2.jpg" &gt;
&lt;br&gt;&lt;br&gt;
&lt;/p&gt;
&lt;p&gt;
Once that is installed, you get a new &lt;b&gt;POP3 Service&lt;/b&gt; console where you can manage mailboxes for users.&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/8.30.2005FullEmail3.jpg" &gt;
&lt;br&gt;&lt;br&gt;
&lt;/p&gt;
&lt;p&gt;
If I'm using this in a BizTalk scenario, then my SMTP adapter will address email to a mailbox that's been setup in the POP3 console.
Notice that the &lt;b&gt;SMTP Server&lt;/b&gt; is also set to my local machine.&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/8.30.2005FullEmail4.jpg" &gt;
&lt;br&gt;&lt;br&gt;
&lt;/p&gt;
&lt;p&gt;
Finally, if you have Outlook installed, you can point to the new valid POP3 account, and actively poll it.  In my case, I send
BizTalk Server 2006 suspended messages (via our new routing of error messages), and workflow messages via SMTP to this account.  
The screenshot below
demonstrates receiving my human workflow email in Outlook, then viewing the BizTalk message attachment as an InfoPath form.  
The user gets full interaction with the BizTalk system (and naturally any system it integrates with) without leaving Outlook or InfoPath.  
Come on, that's good stuff right there.&lt;br&gt;&lt;br&gt;
&lt;img src="http://www.seroter.com/BlogPics/8.30.2005FullEmail5.jpg" &gt;
&lt;br&gt;&lt;br&gt;
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=458088" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/BizTalk/default.aspx">BizTalk</category><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item><item><title>MSN Virtual Earth Is Pretty Hot</title><link>http://blogs.msdn.com/richardbpi/archive/2005/07/25/442989.aspx</link><pubDate>Mon, 25 Jul 2005 18:00:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:442989</guid><dc:creator>rseroter</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/richardbpi/comments/442989.aspx</comments><wfw:commentRss>http://blogs.msdn.com/richardbpi/commentrss.aspx?PostID=442989</wfw:commentRss><description>&lt;span style="font-family:arial;font-size:10pt"&gt;
&lt;p&gt;
Enough about Google Maps (which is still darn cool), let's throw props at the &lt;a href="http://virtualearth.msn.com/" class="myLink"&gt;MSN Virtual Earth&lt;/a&gt; guys!  Very nice stuff.  I like the ability
to zoom in and out using my mouse wheel, and I actually was able to zoom in closer than with Google Maps.  Also pretty neat that when you are viewing
a particular area, and then do a "business" search (or even generic like "fast food"), it finds the ones that exist in the viewable area.
&lt;/p&gt;
&lt;p&gt;
&lt;a href="http://channel9.msdn.com/default.aspx" class="myLink"&gt;Channel9&lt;/a&gt; has even more great stuff on it.
&lt;/p&gt;
&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=442989" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/richardbpi/archive/tags/Other/default.aspx">Other</category></item></channel></rss>