Microsoft Windows Workflow Foundation Step by Step Comments and Corrections
On This PageSUMMARY
This article contains comments, corrections, and information about known errors relating to the Microsoft Press book Microsoft Windows Workflow Foundation Step by Step, 0-7356-2335-X. The following topics are covered:
MORE INFORMATIONCD-ROM: Revised Code for Chapters 6, 8, and 14CD-ROM: After you install the sample code from the CD, the sample codes for various chapters are placed, by default, in the \My Documents\Microsoft Press folder on the hard disk.We have updated sample code for Chapters 6, 8 and 14. Please download the updated sample code to replace the sample code on the hard disk for these chapters. WF6-8-14.exe (http://download.microsoft.com/download/5/4/b/54ba6499-4a6b-46e0-ad7c-a3b4d1f22f09/wf6-8-14.exe) For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base: 119591 (http://support.microsoft.com/kb/119591/en-us/) How to Obtain Microsoft Support Files from Online Services Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file. Page xxvii: Reference to Online Companion Content is incorrectOn page xxvii, the section titled "Online Companion Content" reads:"Online Companion Content The online companion content page has content and links related to this book, including a link to the Microsoft Press Technology Updates Web page. The online companion content page for this book can be found at www.microsoft.com/mspress/companion/0-7356-2335-4/" Disregard this entire section as there is no companion content website for this title. Page 7: Correction to Windows SDK download locationOn page 7, in the first bullet, the URL for downloading the Windows SDK has changed.Change: “http://www.microsoft.com/downloads/details.aspx?familyid=7614FE22-8A64-4DFB-AA0C-DB53035F40A0&displaylang=en” To: “http://www.microsoft.com/downloads/details.aspx?FamilyID=4377F86D-C913-4B5C-B87E-EF72E5B4E065&displaylang=en” Page 19: Missing characters from regular expressionsOn page 19, the first two lines of code in step 4 are missing some characters.Change: To: Page 24: Correction to WorkflowRuntime instanceOn page 24, in the first paragraph, the statement about WorkflowRuntime instance is incorrect.Change: “The WF runtime and your application execute together in a .NET AppDomain, and there can be only one instance of WorkflowRuntime per AppDomain. Attempting to create a second instance of WorkflowRuntime in a single AppDomain results in an InvalidOperationException.” To: “The WF runtime and your application execute together in a .NET AppDomain. Although early in WF’s history there could be only a single instance of the WorkflowRuntime per AppDomain, contemporary versions allow multiple instances.” Page 28: Correction To WorkflowRuntime InstanceOn page 28, under "Building a Workflow Runtime Factory", the statement about WorkflowRuntime is incorrect.Change: “I mentioned this previously in the chapter, but it is important enough to mention again—there can be only a single instance of WorkflowRuntime per AppDomain. And because the majority of .NET applications use only a single AppDomain, it necessarily follows that you can generally use only a single instance of WorkflowRuntime in your application. Whenever I hear “use only a single instance,” I naturally think of using a combination of the singleton and factory patterns. The singleton pattern, if you’re unfamiliar with patterns, is simply a mechanism for assuring that no matter how many times your application requests instances of the singleton object, only one instance of the singleton is ever given out. This is typically done for objects that are considered “expensive” to create, such as objects that consume a large number of resources or take a significant amount of time to be created.” To: “When I started writing this book, there could be only a single instance of WorkflowRuntime per AppDomain. And because the majority of .NET applications use only a single AppDomain, it necessarily followed that you could generally use only a single instance of WorkflowRuntime in your application. Since its release, WF allows more than one WorkflowRuntime instance per AppDomain, but I find the workflow factory I show here to still be a useful tool, if only because you can collect runtime customizations (discussed in later chapters) in one place and have a single place in your code to shut it down. Whenever I hear “use only a single instance,” even though we’re allowed more than one instance in this case, I naturally think of using a combination of the singleton and factory patterns. The singleton pattern, if you’re unfamiliar with patterns, is simply a mechanism for assuring that no matter how many times your application requests instances of the singleton object, only one instance of the singleton is ever given out. This is typically done for objects that are considered “expensive” to create, such as objects that consume a large number of resources or take a significant amount of time to be created.” Page 36: _waitHandle should be waitHandleOn page 36, in point 6, the underscore in _waitHandle shouldbe be deleted.Change: "6. We'll need to create the _waitHandle object" To: "6. We'll need to create the waitHandle object" Page 38: "Create a single instance of Workflow-Runtime per AppDomain" should be "Create an instance of Workflow-Runtime"On page 38, under "Chapter 2 Quicke Reference", "Create a single instance of Workflow-Runtime per AppDomain" should be "Create an instance of Workflow-Runtime".Change: “Add a reference to the System.Workflow.Runtime assembly. Create a single instance of Workflow- Runtime per AppDomain, and start the runtime by calling WorkflowRuntime.StartRuntime or by creating a workflow instance.” To: “Add a reference to the System.Workflow.Runtime assembly. Create an instance of Workflow- Runtime. Start the runtime by calling WorkflowRuntime.StartRuntime or by creating a workflow instance.” Page 50: Correction to step 2On page 50, in step 2, it states:"2. If we were to compile the application now, WorkflowHost would fail to compile..." But at this time the code isn't there, it has to be typed in in the next steps. So compiling causes no error. To fix this, move step 2 down, making it step 5. The current steps 3 – 5 would then become steps 2 – 4. Page 50: Delete Tip boxOn page 50, the text in the Tip box doesn't help. Bacuse it is not possible to select simultanous entries on two tabs. If you change the tab and click OK, the first selected references will not be inserted. Because of this the tip box should be deleted.Page 61: “class MyClass” should be “class MyClass : DependencyObject”On page 61, there is correction to the code sample at the top of the page.Change: To: Page 76: ActivityTrackingPoint should be ActivityTrackPointOn page 76, in the last paragraph, "ActivityTrackingPoint" should be "ActivityTrackPoint".Page 88: GetWorkflowRuntime should be WorkflowRuntimeOn page 88, in step 6, GetWorkflowRuntime should be WorkflowRuntime.Change: “...following the line of code calling GetWorkflowRuntime.“ To: “...following the line of code that creates a new instance of WorkflowRuntime.“ Page 89: Delete step 2On page 89, delete step 2 because the incomplete example file already contains these using-directives.Delete: "2. Add the using statements for configuration and workflow tracking to the top of the file: "Page 90: SqlTrackingService should be SqlTrackingQueryOn page 90 in the middle of the page, there is an incorrect class name:Change: "The query is performed by SqlTrackingService.TryGetWorkflow." To: "The query is performed by SqlTrackingQuery.TryGetWorkflow." Page 92: Add "using System.Workflow.ComponentModel" to step 2On page 92, in step 2, the "using System.Workflow.ComponentModel" should be added to the code.Change: To: Page 113: System.Workflow.Activity should be System.Workflow.ActivitiesOn page 113, in step 11, "System.Workflow.Activity" should be "System.Workflow.Activities".Page 114: Correction to step 14On page 114, in step 4,Change: "(the method containing the code we added in the preceding step)" To: "(the method containing the code we'll add in the next step)" Page 116: First character of type must be upper-caseOn page 116, in step 18, the first character of type must be upper-case.Change: To: Page 122: WorkingStore should be WorkflowStoreOn page 122, in step 9, the database name is wrong.Change: "This should be enought time to examine the WorkingStore InstanceState database table." To: "This should be enought time to examine the WorkflowStore InstanceState database table." Page 123: Correction to script namesOn page 123, under "Chapter 6 Quick Reference", the scripts have the wrong names (remove "workflow" in the names).Change: "You'll need to execute both the SqlWorkflowPersistenceService_Schema.sql script and the SqlWorkflowPersistenceService_Logic.sql script." To: "You'll need to execute both the SqlPersistenceService_Schema.sql script and the SqlPersistenceService_Logic.sql script." Page 159: First "base constructor" should be "constructor"On page 159, in the third paragraph, the first reference to "base constructor" should be "constructor".Change: "we must provide a base constructor that accepts the instance ID (a Guid), which in turn passes the instance ID to the base constructor," To: "we must provide a constructor that accepts the instance ID (a Guid), which in turn passes the instance ID to the base constructor," Page 162: MVDataconnector.cs should be MVDataConnector.csOn page 162, at the bottom of the page, the title of Listing 8-3 is incorrect.Change: "Listing 8-3 MVDataconnector.cs completed" To: "Listing 8-3 MVDataConnector.cs completed" Page 179: Workflow2.Workflow1 should be Workflow2.Workflow2On page 179, in step 10, there is an error in the name.Change: "(Workflow2.Workflow1 is the fully qualified name)" To: "(Workflow2.Workflow2 is the fully qualified name)" Page 194: Incorrect property nameOn page 194, in the Tip box, the property name is incorrect.Change: "...response property directly" To: "...responses property directly" Page 200: Method should be PropertyOn page 200, in Table 9-1, the left column heading is incorrect.Change: "Method" To: "Property". Page 200: Method should be EventOn page 200, in Table 9-2, the left column heading is incorrect.Change: "Method" To: "Event". Page 236: if (_service == null) should be if (value != null)On page 236, in Listing 10-1, there is an error in the code sample.Change: To: Note: there are two instances of this code, both need to be changed. Page 264: setlevel1 should be setLevel1On page 264, in point 29, in line 3, there is an incorrect property name.Change: "bound setlevel1’s Level property " To: "bound setLevel1’s Level property " Page 280: Extra bracket in codeOn page 280, in the code sample above the heading "Explicit Chaining", there is an extra bracket in the line of code.Change: To: Page 286: WorkflowComplete should WorkflowCompletedOn page 286, in point 8, in lines 5 and 6, the event name is incorrect.Change: "WorkflowComplete event" To: "WorkflowCompleted event" Page 332: Correction to last paragraphOn page 332, in the last paragraph,Change: “This doesn’t affect the workflow, but rather resets the user interface buttons.” To: “This causes the application to restart, which reloads the workflow runtime (since we hit a terminal condition, after all) and resets the user interface. (Note that a real soda machine would return to the initial state to wait for another customer, but I wanted to show a terminal state in action.)” Page 352: DefaultSettings should be DefaultSettingsSectionOn page 352, in the last Note box, the settting name is incorrect.Change: "System.Transactions.Configuration.DefaultSettings.Timeout" To: "System.Transactions.Configuration.DefaultSettingsSection.Timeout" Page 386: "select Workflow Activity Library" should be "select Workflow"On page 386, in step 4, there is an error.Change: "select Workflow Activity Library" To: "select Workflow" Page 396: CorrelationIntializer should be CorrelationInitializerOn page 396, in the second line from from bottom, the attribute name is missing a letter i.Change: "CorrelationIntializer" To: "CorrelationInitializer" Page 432: Shift+F5 should be Ctrl+F5On page 432, in step 39, the key name is wrong.Change: "To execute the application, press Shift+F5" To: "To execute the application, press Ctrl+F5" Page 469: Shift+F5 should be Ctrl+F5On page 469, in step 8, the key name is wrong.Change: "To execute the application, press Shift+F5" To: "To execute the application, press Ctrl+F5" Microsoft Press is committed to providing informative and accurate books. All comments and corrections listed above are ready for inclusion in future printings of this book. If you have a later printing of this book, it may already contain most or all of the above corrections.
| Article Translations
|
Back to the top
