Purchase Order Processing if you are Manually Placing Orders Using MS Server
Contents
Tutorial 2: Purchase Order Process
Lesson 1: Set Up the Supplier Side
Step 1: Set Up the Accounts for the Tutorial
Step 2: Windows XP and Windows 2000 Only -
Enable Web Service Publishing
Step 3: Exclude the Root Directory from
Windows SharePoint Services Managed Paths
Step 4: Set Up the Supplier Web Service
Lesson 2: Create the B2B Solution
Step 2: Add the Projects to the Solution
Step 3: Add a Reference to the Supplier's
Web Service
Step 4: Add Existing Schemas and Maps
Lesson 3: Add Functoids to the Map
Step 1: Add a Date/Time Functoid to the Map
Step 2: Add a Multiplication Functoid to the
Map
Step 3: Add a Looping Functoid to the Map
Step 4: Add a Record Count Functoid to the
Map
Step 5: Add a Cumulative Sum Functoid to the
Map
Step 6: Assign a Constant Value in the Map
Step 7: Build the B2BSchema Project and Test
the Map
Lesson 4: Design the Purchase Order Process
Step 1: Add an Orchestration to the Solution
Step 2: Add a Reference to the B2BSchemas
Project
Step 3: Create the Purchase Order Process
Step 4: Create the Message Instance Variables
Step 5: Configure the Message Assignment
Shape
Step 6: Configure the Transform Shape
Step 7: Create and Configure the Internal
Ports
Step 8: Create and Configure the External
Port
Lesson 5: Deploy and Test the Solution
Step 1: Build and Deploy the Solution
Step 2: Configure and Start the Application
In this tutorial, you automate generating and sending purchase orders to a supplier.
This tutorial expands the solution that begins in Tutorial 1: Enterprise Application Integration by adding an inventory procurement solution that automates the exchange of data between the Enterprise Resource Planning (ERP) solution and an outside supplier that fulfills purchase orders. In the tutorial, a Web service acts as the supplier.
In Tutorial 1: Enterprise Application Integration, you create an inventory replenishment business solution. The solution automates the exchange of data between a warehouse and an ERP system.
When the inventory at the warehouse reaches a certain level, the warehouse sends a replenishment request to BizTalk Server. If the request is approved, BizTalk Server sends it to the ERP system. When the ERP system receives the approved request, the ERP system generates a purchase order (PO).
The scenario in this tutorial begins when the ERP process generates the purchase order. Within the purchase order solution, several things happen:
1. The ERP system generates a purchase order.
2. BizTalk Server maps the purchase order to the CommonPO schema.
3. BizTalk Server routes the CommonPO to the supplier.
4. The ERP system sends a purchase order confirmation message to the warehouse.
5. The ERP system receives an advance shipping notice from the supplier that indicates what will be shipped and when.
BizTalk Server 2006 ensures that the ERP system and the supplier interact smoothly and efficiently. This includes applying business rules to the payment approval process and routing the payment appropriately.
The scenario is continued in Tutorial 3: Invoice and Payment Process.
For information about downloading a Microsoft Office Word 2003 version of the btsBizTalkServer2006 Tutorials, see Step 6: Print the Tutorials.
· Lesson 1: Set Up the Supplier Side
· Lesson 2: Create the B2B Solution
· Lesson 3: Add Functoids to the Map
· Lesson 4: Design the Purchase Order Process
· Lesson 5: Deploy and Test the Solution
In this lesson, you set up the supplier side of the scenario.
· Step 1: Set Up the Accounts for the Tutorial
· Step 2: Windows XP and Windows 2000 Only - Enable Web Service Publishing
· Step 3: Exclude the Root Directory from Windows SharePoint Services Managed Paths
· Step 4: Set Up the Supplier Web Service
![]()
Time to complete: 7 minutes
Objective: In this step, you add the account you used to install and configure BizTalk Server 2006 to the BizTalk Isolated Host Users and the IIS_WPG Windows user groups.
Purpose: You must add the account you used to install and configure BizTalk Server 2006 to a Windows user group. The following table describes the user group you must add the account to for each operating system.
|
Operating system |
User group |
Description |
|
Windows XP, Windows 2000 Server, and Windows Server 2003 |
BizTalk Isolated Host Users |
The BizTalk Isolated Host Users group gives transports that run outside of the BizTalk Server process, such as HTTP and SOAP transports, access to BizTalk Server databases. The BizTalk Isolated Host Users group provides Windows Integrated Security access to the Microsoft SQL Server computer that contains the BizTalk Management database.
The BizTalk Management database is also referred to as the BizTalk Configuration database. |
|
Windows Server 2003 only |
IIS_WPG |
The Information Services Worker Process user group provides the minimum set of privileges that are required by IIS, and it provides a convenient way to use a specific user for the identity account without having to manually assign the privileges to that identity. In cases where the account is not in the IIS_WPG group and does not have the appropriate permissions, the worker process fails to start. |
Note
This procedure assumes that the account you are adding to these groups already exists on the computer.
Note the following requirements before you begin this step:
· Before you begin this step you must complete the steps in Before You Begin the Tutorials.
· You must log on as a member of the BizTalk Server Administrators group.
To
add an account to the BizTalk Isolated Host Users group
|
1. Click Start, point to Programs, point to Administrative Tools, and then click Computer Management. 2. In Computer Management, expand Local Users and Groups, and then click Groups. 3. In the Groups results pane, right-click BizTalk Isolated Host Users, and then click Properties. 4. In the BizTalk Isolated Host Users Properties dialog box, in the Members list, check for the account you are using to set up and run this tutorial. If the account is not in the Members list, do the following: a. Click Add. b. In the Select Users, Computers, or Groups dialog box, in the Enter the object name to select box, type the account name in the form <domain>\account name, and then click OK. 5. Click OK. |
To
add an account to the IIS_WPG group
|
1. Click Start, point to Programs, point to Administrative Tools, and then click Computer Management. 2. In Computer Management, expand Local Users and Groups, and then click Groups. 3. In the Groups results pane, right-click IIS_WPG, and then click Properties. 4. In the IIS_WPG Properties dialog box, in the Members list, check for the account you are using to set up and run this tutorial. If the account is not in the Members list, do the following: a. Click Add. b. In the Select Users, Computers, or Groups dialog box, in the Enter the object name to select box, type the account name in the form <domain>\account name, and then click OK. 5. Click OK. |
In this step, you added the account you used to install and configure BizTalk Server 2006 to the BizTalk Isolated Host Users and the IIS_WPG Windows user groups.
You configure Internet Information Services (IIS) and Windows user and group accounts to enable Web service publishing in Step 2: Windows XP and Windows 2000 Only - Enable Web Service Publishing.
Lesson 1: Set Up the Supplier Side
Step 2: Windows XP and Windows 2000 Only - Enable Web Service Publishing
Step 3: Exclude the Root Directory from Windows SharePoint Services Managed Paths
Step 4: Set Up the Supplier Web Service
![]()
Time to complete: 5 minutes
Objective: In this step, you enable Web service publishing by configuring Internet Information Services (IIS) and Windows user and group accounts.
Purpose: Publishing Web services enables you to create a Web service that can submit messages to BizTalk Server for use by orchestrations and other send adapters. You use the BizTalk Web Services Publishing Wizard to create published Web services.
On Windows XP and Windows 2000 Server, the BizTalk Server Web services run in the ASP.NET worker process (aspnet_wp.exe). This process runs under the ASPNET user context by default. To provide access to the BizTalk Management database, you must add the local ASP.NET user account to the BizTalk Isolated Host Users group.
For more information about publishing Web services in BizTalk Server 2006, see Publishing Web Services.
Important
The following procedures provide the steps required to enable Web service publishing for the tutorials for Windows 2000 Server. Do not perform the tasks in this step if you have Windows Server 2003 installed.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 1: Set Up the Accounts for the Tutorial.
· You must log on as a member of the BizTalk Server Administrators group.
To
add ASPNET to the BizTalk Isolated Host Users group
|
1. Click Start, point to Programs, point to Administrative Tools, and then click Computer Management. 2. In Computer Management, expand Local Users and Groups, and then click Groups. 3. In the Groups results pane, right-click BizTalk Isolated Host Users, and then click Properties. 4. In the BizTalk Isolated Host Users Properties dialog box, in the Members list, click Add. 5. In the Select Users, Computers, or Groups dialog box, in the Enter the object name to select box, type ASPNET, and then click OK.
If BizTalk Isolated Host was installed as Trusted, the user that acquires authentication when running the Web service must also be added to the BizTalk Isolated Host Users group. For instructions, see Step 1: Set Up the Accounts for the Tutorial. When using anonymous access, this user account is usually the IUSR_<machine name> account. 6. Click OK to close the BizTalk Isolated Host Users Properties dialog box. For information about that specific ASP.NET account, see http://go.microsoft.com/fwlink/?LinkId=21106. |
In this step, you enabled Web service publishing by configuring Internet Information Services (IIS) and Windows user and group accounts.
You exclude the root directory from Microsoft Windows SharePoint Services managed paths in Step 3: Exclude the Root Directory from Windows SharePoint Services Managed Paths.
Lesson 1: Set Up the Supplier Side
Step 1: Set Up the Accounts for the Tutorial
Step 3: Exclude the Root Directory from Windows SharePoint Services Managed Paths
Step 4: Set Up the Supplier Web Service
![]()
Time to complete: 3 minutes
Objective: In this step, you exclude the root directory from Microsoft Windows SharePoint Services managed paths.
Purpose: You must exclude the root directory from Microsoft Windows SharePoint Services managed paths if you have Microsoft Windows SharePoint Services installed. Microsoft Windows SharePoint Services is a requirement for installing the BizTalk Server 2006 Business Activity Services feature.
Because Windows SharePoint Services is configured in the default Web site, it can interfere with Web services. By excluding the root directory from Windows SharePoint Services managed paths, you enable Web services to co-exist with Windows SharePoint Services.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 2: Windows XP and Windows 2000 Only - Enable Web Service Publishing.
Note
If you are using Windows Server 2003, you should not perform Step 2.
· You must log on as a member of the BizTalk Server Administrators group.
To
exclude the root directory from Windows SharePoint Services managed paths
|
1. Click Start, point to Programs, point to Administrative Tools, and then click SharePoint Central Administration. 2. On the Windows SharePoint Services Central Administration page, in the Virtual Server Configuration section, click Configure virtual server settings. 3. On the Virtual Server List page, click Default Web Site. 4. On the Virtual Server Settings page, in the Virtual Server Management section, click Define managed paths. 5. On the Define Managed Paths page, in the Included Paths section, select the (root) check box, and then click Remove selected paths. 6. Close the browser window. |
In this step, you excluded the root directory from Microsoft Windows SharePoint Services managed paths.
You enable Web service publishing by configuring Internet Information Services (IIS) and Windows user and group accounts in Lesson 2: Create the B2B Solution.
Lesson 1: Set Up the Supplier Side
Step 1: Set Up the Accounts for the Tutorial
Step 2: Windows XP and Windows 2000 Only - Enable Web Service Publishing
Step 4: Set Up the Supplier Web Service
![]()
Time to complete: 4 minutes
Objective: In this step, you run the scripts that set up the supplier Web service.
Purpose: Because the BizTalk Server 2006 tutorials are designed to work on one computer, you use a configuration script to set up the provided supplier Web service. The script creates the virtual directories in Internet Information Services (IIS) and builds the supplier Web service.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 3: Exclude the Root Directory from Windows SharePoint Services Managed Paths.
· You must log on as a member of the BizTalk Server Administrators group.
To
run the supplier Web service configuration scripts
|
1. Use Windows Explorer to run the scripts in the following table in the order presented. Make sure that you wait until each script is finished before starting the next script.
The Setup.bat file in the following procedure assumes that you are running the tutorial from your C drive. If you are running from a different drive, you must edit the file and modify the target location manually.
If you receive a 404 error while running the Setup.bat file, you must use the SharePoint Central Administration tool to exclude the B2BSupplierProcessPO and B2BSupplierProcessPayment virtual directories from Windows SharePoint Services managed paths. For more information, see "About Managed Paths" in Windows SharePoint Services Help.
If there is no C:\Tutorial\Solutions folder, you must install the tutorial files before you proceed. For instructions about installing the tutorial files, see Step 1: Install the Tutorial Files. |
In this step, you ran the scripts that set up the supplier Web service.
You set up the business-to-business (B2B) solution and projects, add a reference to the supplier's Web service, and add existing items to one of the projects in Lesson 2: Create the B2B Solution.
Lesson 1: Set Up the Supplier Side
Step 1: Set Up the Accounts for the Tutorial
Step 2: Windows XP and Windows 2000 Only - Enable Web Service Publishing
Step 3: Exclude the Root Directory from Windows SharePoint Services Managed Paths
In this lesson, you set up the business-to-business (B2B) solution and projects, add a reference to the supplier's Web service, and add existing items to one of the projects.
· Step 1: Open a Blank Solution
· Step 2: Add the Projects to the Solution
· Step 3: Add a Reference to the Supplier's Web Service
· Step 4: Add Existing Schemas and Maps
![]()
Time to complete: 3 minutes
Objective: In this step, you open a new BizTalk solution in Visual Studio 2005.
Purpose: You begin building the B2B solution by opening a blank solution in the Visual Studio environment. In this procedure, you create a solution that contains a project file for the schemas and a separate project file for the orchestrations.
Note the following requirements before you begin this step:
· Before you begin this step you must complete the steps in Lesson 1: Set Up the Supplier Side.
· You must log on as a member of the BizTalk Server Administrators group.
To
open a blank solution in Visual Studio
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. On the File menu, point to New, and then click Project. 3. In the New Project dialog box, do the following:
4. Click OK. Visual Studio 2005 adds both the B2BSolution solution and a B2BSolution project. We do not use the B2BSolution project. |
To
remove the B2BSolution project
|
1. In Solution Explorer, right-click the B2BSolution project, and then click Remove. 2. In the message box, click OK. 3. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Step 2: Add the Projects to the Solution. |
You opened the new BizTalk solution, B2BSolution, in Visual Studio 2005.
You add two projects to the B2BSolution solution that will hold the items that you add to the solution in Step 2: Add the Projects to the Solution.
Lesson 2: Create the B2B Solution
Step 2: Add the Projects to the Solution
Step 3: Add a Reference to the Supplier's Web Service
Step 4: Add Existing Schemas and Maps
![]()
Time to complete: 4 minutes
Objective: In this step, you add two projects to the B2BSolution solution that will hold the items that you add to the solution.
Purpose: The core element of your solution is a BizTalk project — a collection of items, such as schemas, orchestrations, message types, and references that you build and generate into an assembly before deploying it. In this procedure, you create a project file for the schemas and a separate project file for the orchestration that will be used in the business-to-business (B2B) process.
Important
Do not change the name of a project after you create it. The project name is automatically included in the namespaces for all items within the project. Changing the name of a project after you create it causes compilation errors because the namespace in each item does not match the name of the project.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 1: Open a Blank Solution.
· You must log on as a member of the BizTalk Server Administrators group.
To
add a new project to your solution
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, right-click Solution 'B2BSolution', point to Add, and then click New Project. 5. In the Add New Project dialog box, do the following:
6. Click OK. 7. Repeat steps 4 through 6 to create a second project in the solution named B2BOrchestrations. 8. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Step 3: Add a Reference to the Supplier's Web Service. |
You added two projects to B2BSolution to hold the BizTalk Server objects you will add to the solution.
You add a Web reference that connects the B2BSolution to the supplier's Web service in Step 3: Add a Reference to the Supplier's Web Service.
Lesson 2: Create the B2B Solution
Step 3: Add a Reference to the Supplier's Web Service
Step 4: Add Existing Schemas and Maps
![]()
Time to complete: 4 minutes
Objective: In this step, you add a Web reference that connects the B2BSolution to the supplier's Web service.
Purpose: When you add a Web reference, the items within the Web service become available to your solution. The supplier Web service that you use for this tutorial has two services, one for the purchase order and one for the payment. You add both in the following procedure.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 2: Add the Projects to the Solution.
· You must log on as a member of the BizTalk Server Administrators group.
To
add references to the supplier's Web service
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, in the B2BSchemas project, right-click References, and then click Add Web Reference. 5. In the Add Web Reference dialog box, in the URL combo box, type http://localhost/B2BSupplierProcessPO/Process.asmx, and then click Go. · Important If http://localhost/B2BSupplierProcessPO/Process.asmx cannot be found, make sure that you completed all of the steps in Before You Begin the Tutorials. Additionally, make sure you completed all of the steps in Lesson 1: Set Up the Supplier Side. 6. When the service is found, click Add Reference. 7. Repeat steps 4 through 6 for http://localhost/B2BSupplierProcessPayment/Payment_Service.asmx
localhost and localhost1 are now listed in Solution Explorer under Web References. 8. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Step 4: Add Existing Schemas and Maps. |
You added Web references for the supplier Web services to the B2BSchemas project.
You add existing schemas and maps to the B2BSchemas project in Step 4: Add Existing Schemas and Maps.
Lesson 2: Create the B2B Solution
Step 2: Add the Projects to the Solution
Step 4: Add Existing Schemas and Maps
![]()
Time to complete: 3 minutes
Objective: In this step, you add existing schemas and maps to the B2BSchemas project.
Purpose: We have provided the schemas and maps you need to complete the tutorial. You must add the schemas and maps to the B2BSchemas project.
For information about creating schemas and maps from scratch, see Tutorial 1: Enterprise Application Integration.
Note the following requirements before you begin this step:
· Before you begin this step you must complete the steps in Step 3: Add a Reference to the Supplier's Web Service.
· You must log on as a member of the BizTalk Server Administrators group.
To
add existing schemas and maps to your project
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, right-click B2BSchemas, point to Add, and then click Existing Item. 5. In the Add Existing Item dialog box, navigate to C:\Tutorial\Solutions\Schemas, and then do the following: Press CTRL while you click the following schemas and maps: · AdvancedShipNotice.xsd · CommonBaseTypes.xsd · CommonInvoice.xsd · InvoiceToPayment.btm · MapToCommonPO.btm · PO.xsd
You will use the PO.xsd schema and the MapToCommonPO.btm map in this lesson, and the remaining schemas and map in Tutorial 3: Invoice and Payment Process. 6. Click Add. 7. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Lesson 3: Add Functoids to the Map. |
In this step, you added existing schemas and maps to the B2BSchemas project.
You add functoids to the MapToCommonPO map that you added to the B2BSchemas project in Lesson 3: Add Functoids to the Map.
Lesson 2: Create the B2B Solution
Step 2: Add the Projects to the Solution
Step 3: Add a Reference to the Supplier's Web Service
In this lesson, you add functoids to the MapToCommonPO map that you added to the B2BSchemas project in the previous lesson. You add functoids to a map to transform data that is mapped from the source schema to the destination schema.
· Step 1: Add a Date/Time Functoid to the Map
· Step 2: Add a Multiplication Functoid to the Map
· Step 3: Add a Looping Functoid to the Map
· Step 4: Add a Record Count Functoid to the Map
· Step 5: Add a Cumulative Sum Functoid to the Map
· Step 6: Assign a Constant Value in the Map
· Step 7: Build the B2BSchema Project and Test the Map
![]()
Time to complete: 3 minutes
Objective: In this step, you add a Date functoid to the MapToCommonPO map.
Purpose: You add functoids to a map to transform data that is mapped from the source schema to the destination schema. The Date functoid you add in this step generates the current date stamp for the CreationDate field in CommonPO. For more information, see Date and Time Functoids [BTS05].
Note the following requirements before you begin this step:
· Before you begin this step you must complete Lesson 2: Create the B2B Solution.
· You must log on as a member of the BizTalk Server Administrators group.
To
add the Date functoid
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BSchemas, and then double-click MapToCommonPO.btm. 5. In MapToCommonPO.btm, expand the Source Schema and the Destination Schema.
Right-click the root node, and click Expand Tree Node. 6. On the View menu, click Toolbox, and then in the Toolbox, click the pushpin to dock it. 7. In the Toolbox, expand Date/Time Functoids, drag the Date functoid to the mapping grid, and drop it parallel to CommonPO\POHeader\CreationDate in the destination schema. 8. In the Destination Schema schema tree, select and drag the CreationDate field to the Date functoid in the mapping grid. 9. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Step 2: Add a Multiplication Functoid to the Map. |
You added a Date functoid to the MapToCommonPO map and connected the Date functoid to the CreationDate field in the destination schema. The Date functoid adds the date to messages that are based on the destination schema.
You add a Multiplication functoid to the MapToCommonPO map in Step 2: Add a Multiplication Functoid to the Map.
Lesson 3: Add Functoids to the Map
Step 2: Add a Multiplication Functoid to the Map
Step 3: Add a Looping Functoid to the Map
Step 4: Add a Record Count Functoid to the Map
Step 5: Add a Cumulative Sum Functoid to the Map
Step 6: Assign a Constant Value in the Map
Step 7: Build the B2BSchema Project and Test the Map
![]()
Time to complete: 4 minutes
Objective: In this step, you add a Multiplication functoid to the MapToCommonPO map.
Purpose: You add functoids to a map to transform data that is mapped from the source schema to the destination schema. You use the Multiplication functoid to multiply the Quantity field by the Price field in the source schema, and place this resulting value in the ExtendedPrice field in the destination schema. For more information, see Mathematical Functoids Reference [BTS05].
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 1: Add a Date/Time Functoid to the Map.
· You must log on as a member of the BizTalk Server Administrators group.
To
add the Multiplication functoid
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BSchemas, and then double-click MapToCommonPO.btm. 5. In MapToCommonPO.btm, expand the Source Schema and the Destination Schema.
Right-click the root node, and click Expand Tree Node. 6. On the View menu, click Toolbox, and then in the Toolbox, click the pushpin to dock it. 7. In the Toolbox, expand MathematicalFunctoids, and then drag the Multiplication functoid to the mapping grid near the Item node in the source schema. 8. In the Source Schema tree, drag the Item\Quantity field to the functoid.
You may have to scroll the schema trees to find the node. You must drag the node to the functoid. Attempting to drag the functoid just moves it within the mapping grid. 9. In the Source Schema tree, drag the Item\Price field to the functoid. 10. In the Destination Schema, expand Item\ItemHeader\<Equivalent>\<ItemHeaderType>, and then drag the Multiplication functoid to the ExtendedPrice field in the Destination Schema tree. 11. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Step 3: Add a Looping Functoid to the Map. |
In this step, you added a Multiplication functoid to the MapToCommonPO map.
You add a Looping functoid to the MapToCommonPO map in Step 3: Add a Looping Functoid to the Map.
Lesson 3: Add Functoids to the Map
Step 1: Add a Date/Time Functoid to the Map
Step 3: Add a Looping Functoid to the Map
Step 4: Add a Record Count Functoid to the Map
Step 5: Add a Cumulative Sum Functoid to the Map
Step 6: Assign a Constant Value in the Map
Step 7: Build the B2BSchema Project and Test the Map
![]()
Time to complete: 4 minutes
Objective: In this step, you add a Looping functoid to the MapToCommonPO map.
Purpose: You add functoids to a map to transform data that is mapped from the source schema to the destination schema. The Looping functoid combines multiple items into a single repeating structure. You use a Looping functoid because there can be several items on a PO. For more information, see Looping Functoid [BTS05].
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 2: Add a Multiplication Functoid to the Map.
· You must log on as a member of the BizTalk Server Administrators group.
To
add a Looping functoid
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BSchemas, and then double-click MapToCommonPO.btm. 5. In MapToCommonPO.btm, expand the Source Schema and the Destination Schema.
Right-click the root node, and then click Expand Tree Node. 6. On the View menu, click Toolbox, and then in the Toolbox, click the pushpin to dock it. 7. In the Toolbox, expand AdvancedFunctoids, and then drag the Looping functoid to the mapping grid near the Item node in the source schema. 8. In the Source Schema tree, drag the Item node to the Looping functoid. 9. In the Destination Schema tree, drag the Item node to the Looping functoid. 10. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Step 4: Add a Record Count Functoid to the Map. |
You added a Looping functoid to the MapToCommonPO map. The Looping functoid causes the Item node of the destination schema to be applied to every instance of the source schema item node (one time for each item in the PO).
You add a Record Count functoid to the MapToCommonPO map in Step 4: Add a Record Count Functoid to the Map.
Lesson 3: Add Functoids to the Map
Step 1: Add a Date/Time Functoid to the Map
Step 2: Add a Multiplication Functoid to the Map
Step 4: Add a Record Count Functoid to the Map
Step 5: Add a Cumulative Sum Functoid to the Map
Step 6: Assign a Constant Value in the Map
Step 7: Build the B2BSchema Project and Test the Map
![]()
Time to complete: 3 minutes
Objective: In this step, you add a Record Count functoid to the MapToCommonPO map.
Purpose: You add functoids to a map to transform data that is mapped from the source schema to the destination schema. You use a Record Count functoid to count the number of items listed in the PO. For more information, see Record Count Functoid [BTS05].
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 3: Add a Looping Functoid to the Map.
· You must log on as a member of the BizTalk Server Administrators group.
To
add a Record Count functoid
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BSchemas, and then double-click MapToCommonPO.btm. 5. In MapToCommonPO.btm, expand the Source Schema and the Destination Schema.
Right-click the root node, and click Expand Tree Node. 6. On the View menu, click Toolbox, and then in the Toolbox, click the pushpin to dock it. 7. In the Toolbox, expand Advanced Functoids, and then drag the Record Count functoid to the mapping grid near the Item node in the source schema. 8. In the Source Schema tree, drag the Item node to the Record Count functoid. 9. In the Destination Schema tree, drag Total\LineItemTotal to the Record Count functoid. 10. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Step 5: Add a Cumulative Sum Functoid to the Map. |
You just added a Record Count functoid to the MapToCommonPO map. The Record Count functoid will count the number of items listed in the common PO message.
You add a Cumulative Sum functoid to the MapToCommonPO map in Step 5: Add a Cumulative Sum Functoid to the Map.
Lesson 3: Add Functoids to the Map
Step 1: Add a Date/Time Functoid to the Map
Step 2: Add a Multiplication Functoid to the Map
Step 3: Add a Looping Functoid to the Map
Step 5: Add a Cumulative Sum Functoid to the Map
Step 6: Assign a Constant Value in the Map
Step 7: Build the B2BSchema Project and Test the Map
![]()
Time to complete: 4 minutes
Objective: In this step, you add a Cumulative Sum functoid to the MapToCommonPO map.
Purpose: You add functoids to a map to transform data that is mapped from the source schema to the destination schema. You use a Cumulative Sum functoid to calculate the sum of the quantity of all items ordered. For more information, see Cumulative Functoids Reference [BTS05].
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 4: Add a Record Count Functoid to the Map.
· You must log on as a member of the BizTalk Server Administrators group.
To
add a Cumulative Sum functoid
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BSchemas, and then double-click MapToCommonPO.btm. 5. In MapToCommonPO.btm, expand the Source Schema and the Destination Schema.
Right-click the root node, and then click Expand Tree Node. 6. On the View menu, click Toolbox, and then in the Toolbox, click the pushpin to dock it. 7. In the Toolbox, expand CumulativeFunctoids, and then drag the Cumulative Sum functoid to the mapping grid near the Item node. 8. In the Source Schema tree, drag the Item\Quantity field to the functoid. 9. In the Destination Schema tree, drag the Total\QuantityTotal field to the functoid. 10. In the Toolbox, drag a second Cumulative Sum functoid to the mapping grid and place it to the right of the Multiplication functoid.
Functoids are executed from left to right. When you construct a map that uses more than one functoid, you must consider the relative left-to-right placement of the functoids. The output of a functoid can only be input to another functoid that is farther to the right. 11. On the mapping grid, select the Multiplication functoid and drag it to the Cumulative Sum functoid. 12. In the Destination Schema tree, drag the Total\POTotal field to the Cumulative Sum functoid. 13. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Step 6: Assign a Constant Value in the Map. |
You added two Cumulative Sum functoids to the MapToCommonPO map. The first Cumulative Sum functoid adds up the number of items in a PO. The second Cumulative Sum functoid adds up the total value of the PO (item 1: Quantity x Price + item 2: Quantity x Price, and so on).
You add a constant value to the map in Step 6: Assign a Constant Value in the Map.
Lesson 3: Add Functoids to the Map
Step 1: Add a Date/Time Functoid to the Map
Step 2: Add a Multiplication Functoid to the Map
Step 3: Add a Looping Functoid to the Map
Step 4: Add a Record Count Functoid to the Map
Step 6: Assign a Constant Value in the Map
Step 7: Build the B2BSchema Project and Test the Map
![]()
Time to complete: 2 minutes
Objective: In this step, you add a constant value to the map.
Purpose: You assign a constant value to a field in the destination schema for the name of your company (My Company Name). This will be the value of the BillTo/Address/Name field for every message based on the destination schema.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 5: Add a Cumulative Sum Functoid to the Map.
· You must log on as a member of the BizTalk Server Administrators group.
To
assign a constant value to the BillTo record
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BSchemas, and then double-click MapToCommonPO.btm. 5. In MapToCommonPO.btm, expand the Destination Schema.
Right-click the root node, and then click Expand Tree Node. 6. In the Destination Schema tree, click the BillTo/Address/Name field. 7. On the View menu, click Properties Window. 8. In the Properties pane, in the Value combo box, type My Company Name, and then press ENTER. 9. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Step 7: Build the B2BSchema Project and Test the Map. |
You assigned "My Company Name" as the constant value of the BillTo/Address/Name field in the destination schema. Every message based on the schema will contain this value.
You build the B2BSchemas project and you test the MapToCommonPO map in Step 7: Build the B2BSchema Project and Test the Map.
Lesson 3: Add Functoids to the Map
Step 1: Add a Date/Time Functoid to the Map
Step 2: Add a Multiplication Functoid to the Map
Step 3: Add a Looping Functoid to the Map
Step 4: Add a Record Count Functoid to the Map
Step 5: Add a Cumulative Sum Functoid to the Map
Step 7: Build the B2BSchema Project and Test the Map
![]()
Time to complete: 7 minutes
Objective: In this step, you build the B2BSchemas project and you test the MapToCommonPO map.
Purpose: After you create the B2BSchemas project and add the necessary items to it, you must build the project to generate an assembly. An assembly is a collection of resources in the project, such as schemas and maps that are stored in a DLL file.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 6: Assign a Constant Value in the Map.
· You must log on as a member of the BizTalk Server Administrators group.
To
build the B2BSchemas project
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, right-click B2BSchemas, and then click Properties. 5. In the B2BSchemas Property Pages dialog box, in the tree control, expand Common Properties, and then click Assembly. 6. On the Assembly page, click the Assembly Key File ellipsis […]. 7. In the Assembly Key File dialog box, do the following:
8. Click Open. 9. In the B2BSchemas Properties Pages dialog box, in the tree control, expand Configuration Properties, and then click Deployment. 10. On the Deployment page, do the following:
11. Click OK. 12. In Solution Explorer, right-click B2BSchemas, and then click Build. |
To
test the map against an instance of the PO
|
1. In Solution Explorer, right-click MapToCommonPO.btm, and then click Properties. 2. In the MapToCommonPO.btm Property Pages dialog box, click the TestMap Input Instance ellipsis [...].
The MapToCommonPO.btm Property Pages dialog box uses a grid control. You must click in the property row to expose the property control. A control is a device you use to select options, such as a drop-down list. 3. In the Select Input File dialog box, browse to C:\Tutorial, select POInstance.xml, and then click Open. 4. In the MapToCommonPO.btm Property Pages dialog box, in the TestMapInput drop-down list, select XML, and then click OK. 5. In Solution Explorer, right-click MapToCommonPO.btm, and then click Test Map. 6. On the Output tab located at the bottom of the screen, verify that the test succeeded and open the output file specified on the Output tab. The output file shows you what the PO XML document looks like after it is transformed by the map. 7. On the File menu, click Save All.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Lesson 4: Design the Purchase Order Process. |
You built the B2BSchemas project and tested the MapToCommonPO map.
You create the orchestration for the B2BSolution in Lesson 4: Design the Purchase Order Process.
Lesson 3: Add Functoids to the Map
Step 1: Add a Date/Time Functoid to the Map
Step 2: Add a Multiplication Functoid to the Map
Step 3: Add a Looping Functoid to the Map
Step 4: Add a Record Count Functoid to the Map
Step 5: Add a Cumulative Sum Functoid to the Map
Step 6: Assign a Constant Value in the Map
In this lesson, you create the orchestration for the B2BSolution. The orchestration receives purchase orders (PO) and then performs a parallel action: On one side, a confirmation message is sent back to the originator of the PO; on the other side, the PO is transformed into a CommonPO message and sent out to the supplier.
· Step 1: Add an Orchestration to the Solution
· Step 2: Add a Reference to the B2BSchemas Project
· Step 3: Create the Purchase Order Process
· Step 4: Create the Message Instance Variables
· Step 5: Configure the Message Assignment Shape
· Step 6: Configure the Transform Shape
· Step 7: Create and Configure the Internal Ports
· Step 8: Create and Configure the External Port
![]()
Time to complete: 3 minutes
Objective: In this step, you add an orchestration to the B2BOrchestrations project.
Purpose: An orchestration is a representation of your business process. In later steps, you will add action shapes that automate the business process.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Lesson 3: Add Functoids to the Map.
· You must log on as a member of the BizTalk Server Administrators group.
To
add an orchestration to the project
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, right-click B2BOrchestrations, point to Add, and then click New Item. 5. In the Add New Item dialog box, do the following:
6. Click Add. The following figure shows the orchestration design surface for the B2BProcess orchestration.
If the Toolbox is not docked on the left side, on the View menu, click Toolbox. 7. On the File menu, click Save All to save your work.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to the next step, Step 2: Add a Reference to the B2BSchemas Project. |
In this step, you added a new orchestration to the B2BOrchestrations project.
You add a reference from the B2BOrchestrations project to the B2BSchemas project in Step 2: Add a Reference to the B2BSchemas Project.
Lesson 4: Design the Purchase Order Process
Step 2: Add a Reference to the B2BSchemas Project
Step 3: Create the Purchase Order Process
Step 4: Create the Message Instance Variables
Step 5: Configure the Message Assignment Shape
Step 6: Configure the Transform Shape
Step 7: Create and Configure the Internal Ports
Step 8: Create and Configure the External Port
![]()
Time to complete: 4 minutes
Objective: In this step, you add a reference from the B2BOrchestrations project to the B2BSchemas project.
Purpose: The B2BProcess orchestration processes messages defined with the schemas in the B2BSchemas project. You add a reference from the B2BOrchestrations project to the B2BSchemas project to make the schemas in the B2BSchemas project available to the orchestration in the B2BOrchestrations project. The new reference in the B2BOrchestrations project references the B2BSchemas assembly file (DLL) that you created when you built the B2BSchemas project in Lesson 3.
Note
Notice that after this step, the B2BOrchestrations project is dependent on the B2Bschemas project. This relationship defines the order in which the projects must be built and deployed. You must build your projects in reverse order of dependency, starting from the independent assemblies (in this case B2BSchemas), and then moving on to the assemblies that are dependent upon those developed earlier (in this case B2BOrchestrations).
Note the following requirements before you begin this step:
· You must build the B2BSchemas project before you begin this step. You built the B2BSchemas project in the previous lesson when you completed Step 7: Build the B2BSchema Project and Test the Map.
· Before you begin this step you must complete Step 1: Add an Orchestration to the Solution.
· You must log on as a member of the BizTalk Server Administrators group.
To
add a reference to the B2BSchemas project
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand the B2BOrchestrations project, right-click the References node, and then click Add Reference. 5. In the Add Reference dialog box, click the Projects tab, and then double-click the B2BSchemas project to add it as a selected component. 6. Verify that B2BSchemas is listed as a selected component, and then click OK. 7. In Solution Explorer, right-click the B2BSchemas reference, and then click Properties. 8. In the Properties pane, from the Copy Local drop-down list, select False. 9. In the Properties pane, from the Copy Local drop-down list, select True.
Changing the Copy Local property refreshes the reference. Theoretically, you should be able to set the Copy Local property to False, because that is the setting that ensures that the contents of the B2BSchemas project are available to the B2BOrchestrations project. There is an issue with Visual Studio 2005, however, that makes this inadvisable. For more information, see the Knowledge Base article 313512, "BUG: "Could not copy temporary files to the output directory" error message when you build a solution that contains multiple projects" available at http://go.microsoft.com/fwlink/?LinkId=62208. 10. On the File menu, click Save All to save your work.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to the next step, Step 3: Create the Purchase Order Process. |
In this step, you added a reference from the B2BOrchestrations project to the B2BSchemas project. Adding the reference makes the schemas in the B2BSchemas project available to the B2BOrchestrations project.
You add action shapes to the B2BProcess orchestration in Step 3: Create the Purchase Order Process.
Lesson 4: Design the Purchase Order Process
Step 1: Add an Orchestration to the Solution
Step 3: Create the Purchase Order Process
Step 4: Create the Message Instance Variables
Step 5: Configure the Message Assignment Shape
Step 6: Configure the Transform Shape
Step 7: Create and Configure the Internal Ports
Step 8: Create and Configure the External Port
![]()
Time to complete: 7 minutes
Objective: In this step, you add action shapes to the B2BProcess orchestration.
Purpose: In Orchestration Designer, you define the first part of your business process by using shapes such as Receive, Parallel Actions, Message Assignment, and Transform instead of more complex items, such as documents, schemas, components, and messages.
The Receive shape receives the purchase order (PO) and starts the orchestration. If a Receive shape is the first action in an orchestration, it must have the Activate property set to True to run, unless the orchestration is called by another orchestration.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 2: Add a Reference to the B2BSchemas Project.
· You must log on as a member of the BizTalk Server Administrators group.
To
add the Receive, Parallel Actions, and Construct shapes
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BOrchestrations, and then double-click B2BProcess.odx. 5. In Orchestration Designer, from the Toolbox, drag the Receive shape to the orchestration design surface and drop the shape between the Begin (green circle) and End (red octagon) shapes. The following figure shows the orchestration with the new Receive shape.
6. On the orchestration design surface, right-click the Receive shape, and then click Properties Window. 7. In the Properties pane, change the Name property to Receive_PO and set Activate to True. 8. From the Toolbox, drag the Parallel Actions shape to the orchestration design surface and drop the shape on the connecting line directly below the Receive_PO shape. The Parallel Actions shape expands to show two branches for different actions that take place concurrently but independently. The following figure shows the orchestration with the new Parallel Actions shape.
9. On the orchestration design surface, right-click the Parallel Actions shape, and then click Properties Window. 10. In the Properties pane, change the Name property to Route_PO. 11. From the Toolbox, drag the Message Assignment shape to the orchestration design surface, and drop the shape on the left side in the Route_PO shape.
When you drop the Message Assignment shape on the design surface, Orchestration Designer creates the enclosing Construct Message shape for you. The following figure shows the orchestration with the new Message Assignment shape.
12. On the orchestration design surface, right-click the ConstructMessage_1 shape, and then click Properties Window. 13. In the Properties pane, change the Name property to Construct_POConfirmed. 14. From the Toolbox, drag the Send shape to the orchestration design surface, drop the shape on the connecting line directly below the Construct_POConfirmed shape.
Do not drop the Send shape inside the Construct Message shape. It must be placed outside the Construct Message shape and inside the Parallel Actions shape. The following figure shows the orchestration with the new Send shape.
15. On the orchestration design surface, right-click the Send shape, and then click Properties Window. 16. In the Properties pane, change the Name property to Send_POConfirmed. 17. From the Toolbox, drag the Transform shape to the orchestration design surface, and drop the shape on the right side of the Route_PO shape.
When you drop the Transform shape on the design surface, Orchestration Designer creates the enclosing Construct Message shape for you. The following figure shows the orchestration with the new Transform shape.
18. On the orchestration design surface, right-click the ConstructMessage shape, and then click Properties Window. 19. In the Properties pane, change the Name property to Construct_CommonPO. 20. From the Toolbox, drag the Send shape to the orchestration design surface, and drop the shape on the connecting line directly below the Construct_CommonPO shape. The following figure shows the orchestration with the new Send shape.
21. On the orchestration design surface, right-click the Send shape, and then click Properties Window. 22. In the Properties pane, change the Name property to Send_CommonPO. The following figure shows the completed orchestration.
Some orchestration shapes show an insufficient configuration Smart Tag. You will add the missing information to the shapes in other steps in this lesson. The following figure shows the insufficient configuration Smart Tag.
23. On the File menu, click Save All to save your work.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to the next step, Step 4: Create the Message Instance Variables. |
You began to build the B2BProcess orchestration by adding a Receive shape and a Parallel Actions shape that contains two Construct Message shapes and two Send shapes.
You create variables for the message instances and connect the messages to schemas in Step 4: Create the Message Instance Variables. You added the schemas to the B2BSchemas project in Lesson 2: Create the B2B Solution.
Lesson 4: Design the Purchase Order Process
Step 1: Add an Orchestration to the Solution
Step 2: Add a Reference to the B2BSchemas Project
Step 4: Create the Message Instance Variables
Step 5: Configure the Message Assignment Shape
Step 6: Configure the Transform Shape
Step 7: Create and Configure the Internal Ports
Step 8: Create and Configure the External Port
![]()
Time to complete: 7 minutes
Objective: In this step, you create variables for the message instances and connect the messages to schemas you added to the B2BSchemas project in Lesson 2: Create the B2B Solution.
Purpose: Orchestration Designer uses message instances to manage data. You use a message instance variable to indicate the schema for the message instance.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 3: Create the Purchase Order Process.
· You must log on as a member of the BizTalk Server Administrators group.
To
create the message instance variables
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BOrchestrations, and then double-click B2Bprocess.odx. 5. In the Orchestration View window, right-click Messages, and then click New Message. 6. In the Orchestration View window, right-click Message_1, and then click Properties Window. 7. In the Properties pane, do the following:
8. In the Select Artifact Type dialog box, select B2BSchemas, from the TypeName | Fully Qualified Name list, select B2BSchemas.PO, and then click OK. The following figure shows the Select Artifact Type dialog box.
9. Repeat steps 5 through 8 to create two additional new messages with the following parameters:
10. On the File menu, click Save All to save your work.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to the next step, Step 5: Configure the Message Assignment Shape. |
You defined three message instances for the B2BProcess orchestration. For each message instance, you changed the value of the message instance Identifier property (name), and defined a message type (schema or Web message).
You enter an expression as the POConfirmed message in the B2BProcess orchestration in Step 5: Configure the Message Assignment Shape.
Lesson 4: Design the Purchase Order Process
Step 1: Add an Orchestration to the Solution
Step 2: Add a Reference to the B2BSchemas Project
Step 3: Create the Purchase Order Process
Step 5: Configure the Message Assignment Shape
Step 6: Configure the Transform Shape
Step 7: Create and Configure the Internal Ports
Step 8: Create and Configure the External Port
![]()
Time to complete: 5 minutes
Objective: In this step, you enter an expression as the POConfirmed message in the B2BProcess orchestration.
Purpose: The expression you enter in this step creates the PO_Instance message from the POConfirmed_Instance message.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 4: Create the Message Instance Variables.
· You must log on as a member of the BizTalk Server Administrators group.
To
configure the message assignment shape
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BOrchestrations, and then double-click B2Bprocess.odx. 5. On the orchestration design surface, right-click the Construct_POConfirmed shape, and then click Properties Window. 6. In the Properties pane, from the Messages Constructed drop-down list, select the POConfirmed_Instance check box, and then press ENTER. 7. The following figure shows the Construct_POConfirmed shape properties.
8. In the Construct_POConfirmed shape, double-click the MessageAssignment_1 shape to open BizTalk Expression Editor. 9. In BizTalk Expression Editor, type the following expression:
The following figure shows BizTalk Expression Editor.
10. Click OK to close BizTalk Expression Editor. 11. On the File menu, click Save All to save your work.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to the next step, Step 6: Configure the Transform Shape. |
In this step, you entered an expression as the POConfirmed message in the B2BProcess orchestration.
You specify the MapToCommonPO map in the Transform shape in Step 6: Configure the Transform Shape.
Lesson 4: Design the Purchase Order Process
Step 1: Add an Orchestration to the Solution
Step 2: Add a Reference to the B2BSchemas Project
Step 3: Create the Purchase Order Process
Step 4: Create the Message Instance Variables
Step 6: Configure the Transform Shape
Step 7: Create and Configure the Internal Ports
Step 8: Create and Configure the External Port
![]()
Time to complete: 6 minutes
Objective: In this step, you specify the MapToCommonPO map in the Transform shape.
Purpose: Because the MapToCommonPO map is specified in the Transform shape, the Transform shape uses the map to construct the CommonPO message.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 5: Configure the Message Assignment Shape.
· You must log on as a member of the BizTalk Server Administrators group.
To
configure the Transform shape
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BOrchestrations, and then double-click B2BProcess.odx. 5. On the orchestration design surface, right-click the Construct_CommonPO shape, and then click Properties Window. 6. In the Properties pane, from the Messages Constructed drop-down list, select the CommonPO_Instance check box, and then press ENTER. 7. Double-click the Transform_1 shape. 8. In the Transform Configuration dialog box, select the Existing Map option, and then from the Fully Qualified Map Name drop-down list, select Select from referenced assembly. 9. In the Select Artifact Type dialog box, do the following:
10. Click OK. 11. In the Transform Configuration dialog box, click Source, and then from the Source Transform drop-down list, select PO_Instance.
The Source Transform section of the Transform Configuration dialog box is a grid control. You must click in the cell under Variable Name to expose the control. A control is a device you use to select options, such as a drop-down list. 12. In the Transform Configuration dialog box, click Destination, and then from the Destination Transform drop-down list, select CommonPO_Instance.InputPO_xml.
The red X next to the Destination tab does not go away when you select the destination transform value. Click Source to refresh the dialog box. 13. Click OK. 14. On the File menu, click Save All to save your work.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to the next step, Step 7: Create and Configure the Internal Ports. |
In this step, you specified a source and destination map for the Transform shape. The Transform shape uses the source map to define the data in the incoming message. The Transform shape uses the destination map to transform the incoming message into the outgoing message.
You add two ports to the orchestration in Step 7: Create and Configure the Internal Ports.
Lesson 4: Design the Purchase Order Process
Step 1: Add an Orchestration to the Solution
Step 2: Add a Reference to the B2BSchemas Project
Step 3: Create the Purchase Order Process
Step 4: Create the Message Instance Variables
Step 5: Configure the Message Assignment Shape
Step 7: Create and Configure the Internal Ports
Step 8: Create and Configure the External Port
![]()
Time to complete: 5 minutes
Objective: In this step, you add two ports to the orchestration.
Purpose: The B2BProcess orchestration uses one of the ports you create in this step to receive internal purchase orders, and the other port to send out a purchase order confirmation message.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 6: Configure the Transform Shape.
· You must log on as a member of the BizTalk Server Administrators group.
To
create and configure two Internal ports
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BOrchestrations, and then double-click B2BProcess. 5. In Orchestration Designer, from the Toolbox, drag a Port shape to the left side Port Surface of the Orchestration Design surface parallel to the Receive_PO shape.
When you drop a port onto the Port Surface, the Port Configuration Wizard begins automatically. 6. On the Welcome to the Port Configuration Wizard page, click Next. 7. On the Port Properties page, in the Name field, type ReceivePO_Port, and then click Next. 8. On the Select a Port Type page, do the following:
9. Click Next. 10. On the Port Binding page, do the following:
11. Click Next, and then click Finish. 12. Repeat steps 5 through 11 to configure the port that sends the PO confirmation. Use the following values:
13. On the File menu, click Save All to save your work.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to the next step, Step 8: Create and Configure the External Port. |
You added two internal ports to the orchestration.
You add another port to the orchestration in Step 8: Create and Configure the External Port.
Lesson 4: Design the Purchase Order Process
Step 1: Add an Orchestration to the Solution
Step 2: Add a Reference to the B2BSchemas Project
Step 3: Create the Purchase Order Process
Step 4: Create the Message Instance Variables
Step 5: Configure the Message Assignment Shape
Step 6: Configure the Transform Shape
Step 8: Create and Configure the External Port
![]()
Time to complete: 4 minutes
Objective: In this step, you add another port to the orchestration.
Purpose: The port you add to the orchestration in this step archives the CommonPO. You will reconfigure this port later to send the CommonPO to your supplier's Web service. Because this port will eventually be calling a Web service, access restrictions on this port are set to public, meaning that access is not restricted.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 7: Create and Configure the Internal Ports.
· You must log on as a member of the BizTalk Server Administrators group.
To
create and configure a temporary port to archive the PO
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BOrchestrations, and then double-click B2BProcess.odx. 5. In Orchestration Designer, from the Toolbox, drag a Port shape to the right-side Port Surface, and drop the Port shape parallel to the Send_CommonPO shape.
When you drop a port onto the Port Surface, the Port Configuration Wizard begins automatically. 6. On the Welcome to the Port Configuration Wizard page, click Next. 7. On the Port Properties page, in the Name field, type SendCommonPO_Port,and then click Next. 8. On the Select a Port Type page, do the following:
9. Click Next. 10. On the Port Binding page, do the following:
11. Click Next, and then click Finish. 12. On the File menu, click Save All to save your work.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to the next step, Step 9: Connect the Ports. |
You added an external port to the B2BProcess orchestration.
You connect messages and action shapes to the ports you created in the last two steps in Step 9: Connect the Ports.
Lesson 4: Design the Purchase Order Process
Step 1: Add an Orchestration to the Solution
Step 2: Add a Reference to the B2BSchemas Project
Step 3: Create the Purchase Order Process
Step 4: Create the Message Instance Variables
Step 5: Configure the Message Assignment Shape
Step 6: Configure the Transform Shape
Step 7: Create and Configure the Internal Ports
![]()
Time to complete: 6 minutes
Objective: In this step, you connect messages and action shapes to the ports you created in the last two steps.
Purpose: You connect messages and action shapes to ports to specify how the process sends and receives the messages.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 8: Create and Configure the External Port.
· You must log on as a member of the BizTalk Server Administrators group.
To
select the messages and connect the ports
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, expand B2BOrchestrations, and then double-click B2BProcess.odx. 5. In Orchestration Designer, on the Orchestration Design surface, right-click the Receive_PO action shape, and then click Properties Window. 6. In the Properties pane, from the Message drop-down list, select PO_Instance. 7. Connect the ReceivePO_Port to the Receive_PO action shape by selecting the green arrow-shaped handle in the ReceivePO_Port and dragging it to the green handle on the Receive_PO action shape. 8. Repeat steps 5 through 7 to select messages in a shape, and connect the send ports to the send shapes. Use the following values:
9. On the File menu, click Save All to save your work.
You saved your work. You can safely close Visual Studio 2005 at this time, or you can go to Lesson 5: Deploy and Test the Solution. |
You specified a message instance for the Receive_PO, Send_POConfirmed, and Send_CommonPO action shapes. Then you connected the Receive_PO shape to the ReceivePO_Port, the Send_POConfirmed shape to the SendPOConfirmed_Port, and the Send_CommonPO shape to the SendCommonPO_Port.
You build and deploy the B2BSchemas and B2BOrchestrations projects in Lesson 5: Deploy and Test the Solution.
Lesson 4: Design the Purchase Order Process
Step 1: Add an Orchestration to the Solution
Step 2: Add a Reference to the B2BSchemas Project
Step 3: Create the Purchase Order Process
Step 4: Create the Message Instance Variables
Step 5: Configure the Message Assignment Shape
Step 6: Configure the Transform Shape
Step 7: Create and Configure the Internal Ports
Step 8: Create and Configure the External Port
In this lesson, you build and deploy the B2BSchemas and B2BOrchestrations projects. You bind, enlist, and start the B2BProcess orchestration, and you test the B2B solution.
· Step 1: Build and Deploy the Solution
· Step 2: Configure and Start the Application
![]()
Time to complete: 5 minutes
Objective: In this step, you build and deploy the B2BSchemas and the B2BOrchestrations projects.
Purpose: You build an assembly (project), and then deploy it to place a copy of the assembly in the BizTalk Management database (also known as the Configuration database) and install it in the global assembly cache.
In this step, you deploy both projects (also known as assemblies) in your solution: B2BSchemas.dll and B2BOrchestrations.dll.
You can run the deploy process on the solution. Deploying the solution deploys both projects in the solution, in the proper order. If you deploy the projects individually, you must deploy them in reverse order of dependency, starting from the independent assemblies and then moving on to the assemblies that are dependent upon those developed earlier.
Note
If you find this confusing, there is no need to be concerned. Visual Studio will tell you the order in which you must build and deploy your projects. Just right-click a project, and then click Project Build Order. The Project Dependencies dialog box shows you the build order for your projects and, on the Dependencies tab, shows the dependency relationship between the projects.
In the B2BOrchestrations project, you added a reference to the B2BSchemas project in Step 2: Add a Reference to the B2BSchemas Project. This is because in the B2BSolution solution, the B2BOrchestrations project references schemas in the B2BSchemas project.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Lesson 4: Design the Purchase Order Process.
· You must log on as a member of the BizTalk Server Administrators group.
To
configure build properties for the B2BOrchestrations project
|
1. Click Start, point to Programs, point to Microsoft Visual Studio 2005, and then click Microsoft Visual Studio 2005. 2. In Visual Studio 2005, on the File menu, point to Open, and then click Project/Solution. 3. In the Open Project dialog box, click B2BSolution, and then click Open. 4. In Solution Explorer, right-click B2BOrchestrations, and then click Properties. 5. In the B2BOrchestrations Property Pages dialog box, in the tree control, expand Common Properties, and then click Assembly. 6. On the Assembly page, click the Assembly Key File ellipsis […]. 7. In the Assembly Key File dialog box, do the following:
8. Click Open. 9. In the B2BOrchestrations Properties Pages dialog box, in the tree control, expand Configuration Properties, and then click Deployment. 10. On the Deployment page, do the following:
11. Click OK. |
To
build and deploy the solution
|
1. In Solution Explorer, right-click B2BSolution, and then click Properties. 2. In the Solution 'B2BSolution' Properties Pages dialog box, in the tree control, expand Configuration Properties, and then click Configuration. 3. On the Configuration page, in the Deploy column, select the check boxes for both the B2BSchemas and B2BOrchestrations projects, and then click OK. 4. In Solution Explorer, right-click B2BSolution, and then click Build Solution.
You must wait until the build process completes before you start the deploy process for the B2BSolution project.
If you build the projects individually, you would build B2BSchemas first. If you build projects in the wrong order, the process fails. 5. In Solution Explorer, right-click B2BSolution, and then click Deploy Solution.
If you deploy the projects individually, you would deploy B2BSchemas first. If you deploy projects in the wrong order, the process fails.
You can safely close Visual Studio 2005 at this time, or you can start Step 2: Configure and Start the Application. |
You built and deployed both projects.
You bind, enlist, and start the B2BProcess orchestration so that the orchestration can start processing messages in Step 2: Configure and Start the Application.
Lesson 5: Deploy and Test the Solution
Step 2: Configure and Start the Application
![]()
Time to complete: 8 minutes
Objective: In this step, you configure and start the B2B application.
Purpose: Configuring the B2B application binds the B2BProcess orchestration by selecting a host in which the orchestration process will run. Starting the B2B application enlists the orchestration so that the necessary subscriptions are created in the MessageBox database and the configuration of the associated receive location is verified, and starts the orchestration so that messages can be processed.
Note the following requirements before you begin this step:
· Before you begin this step you must complete Step 1: Build and Deploy the Solution.
· You must log on as a member of the BizTalk Server Administrators group.
To
configure the application
|
1. Click Start, point to Programs, point to Microsoft BizTalk Server 2006, and then click BizTalk Server Administration. 2. In the BizTalk Server Administration console, expand BizTalk Server 2006 Administration, expand BizTalk Group, expand Applications, right-click B2BApplication, and then click Configure. 3. In the Configure Application dialog box, on the B2BProcess tab, do the following:
4. In the ReceivePort1 - Receive Port Properties dialog box, on the General tab, in the Name box, type ReceivePO_ReceivePort. 5. In the ReceivePort1 - Receive Port Properties dialog box, on the Receive Location tab, click New. 6. In the ReceiveLocation1 -- Receive Location Properties dialog box, do the following:
|