To work around this issue, update the Microsoft Dynamics CRM Connector maps on the computer that is running Microsoft BizTalk Server. To do this, follow these steps.
Step 1: Set up the BizTalk Visual Studio Projects for the Microsoft Dynamics CRM Connector
- Create a new blank solution in Microsoft Visual Studio. To do this, follow these steps:
- Start Microsoft Visual Studio .NET 2003.
- On the File menu, click New, and then click Blank Solution.
- In the Name box, type IntegrationSolution as the name of the solution, and then click OK.
- Copy the SchemaMaps folder from the Microsoft Dynamics CRM Connector installation location to the root folder for the blank solution. To do this, follow these steps:
- Locate the installation files for the Microsoft Dynamics CRM Connector.
- Right-click the SchemaMaps folder, and then click Copy.
- Locate the IntegrationSolution solution. By default, the solution is located in the following folder:
C:\Documents and Settings\username\My Documents\Visual Studio Projects
- Open the IntegrationSolution folder.
- Right-click a blank area in the folder, and then click Paste.
- Add the three BizTalk projects in the SchemaMaps folder to the blank solution. To do this, follow these steps:
- On the View menu, click Solution Explorer.
- Right-click the solution in Solution Explorer, click Add, and then click Existing Project.
- Open the SchemaMaps folder, and then open the CRMSchemas folder.
- Double-click the CRMSchemas.btproj file.
- Right-click the solution in Solution Explorer, click Add, and then click Existing Project.
- Open the GPSchemas folder.
- Double-click the GPSchemas.btproj file.
- Right-click the solution in Solution Explorer, click Add, and then click Existing Project.
- Open the Mapscrmgp folder.
- Double-click the Mapscrmgp.btproj file.
- Create a strong name key file to sign the output of each project. To do this, follow these steps:
- Click Start, point to All Programs, point to Microsoft Visual Studio .NET 2003, point to Visual Studio .NET Tools, and then click Visual Studio .NET 2003 Command Prompt.
- At the command prompt, type the following command, and then press ENTER:
sn -k the path in which you want the strong name key file to be written\file_name.snk
- Set up each project to use the strong name key file to sign the output of each project. To do this, follow these steps in Microsoft Visual Studio for each project in the IntegrationSolution solution:
- Right-click the project, and then click Properties.
- Under Common Properties, click Assembly.
- In the Strong Name area, click False in the Assembly Delay Sign box.
- In the Assembly key file box, type the path of the .snk file that you created in step 4.
- Click OK.
- Add references to the integration .dll files. To do this, follow these steps:
- Expand the MapsCRMGP project, expand References, right-click the following references, and then click Remove:
- Microsoft.MbsIntegration.CRMSchemas
- Microsoft.MbsIntegration.GPSchemas
- Microsoft.MbsIntegration.FunctoidsCRMGP
- Right-click References, and then click Add Reference.
- Click Browse, and then locate the Microsoft.MbsIntegration.FunctoidsCRMGP.dll file.
By default, the Microsoft.MbsIntegration.FunctoidsCRMGP.dll file is in the same folder as the Microsoft Dynamics CRM Connector installation files. - Click the Microsoft.MbsIntegration.FunctoidsCRMGP.dll file, and then click Open.
- Right-click References, and then click Add Reference.
- On the Projects tab, select the CRMSchemas project and the GPSchemas project, click Select, and then click OK.
- Change the assembly name for the MapsCRMGP project output. To do this, follow these steps:
- Right-click the MapsCRMGP project, and then click Properties.
- Under Common Properties, click General.
- In the Assembly name box, click Microsoft.MbsIntegration.MapsCRMGPCustom, and then click OK.
Step 2: Update the Crm_account_to_gp_customer.btm BizTalk map
In this step, you use a scripting functoid to remove spaces from the value that is mapped to the CUSTNMBR node. The value that is mapped to the CUSTNMBR node is in the Crm_account_to_gp_customer.btm BizTalk map of the MapsCRMGP project in the solution.
To do this, follow these steps:
- Expand the MapsCRMGP project.
- Expand the AccountCustomer folder.
- Double-click the Crm_account_to_gp_customer.btm file.
- Under Advanced Functoids in the Microsoft Visual Studio toolbox, drag a scripting functoid to the Mapping area.
- On the right side of the mapping file, locate the CUSTNMBR node.
- Locate and then select the link that connects the CUSTNMBR node to the scripting function in the map.
Note When you select the link node, the link node will change to blue. - Click the end of the link that connects the CUSTNMBR node, and then drag that end to the new scripting functoid that you
added to the Mapping area.
- Click the scripting functoid that you connected by using the link, and then drag the scripting functoid to the
CUSTNMBR node.
You should now have a scripting functoid that is linked to another scripting functoid. Additionally, the scripting functoid should be linked
to the CUSTNMBR node. - Right-click the scripting functoid that you added to the Mapping area, and then click Properties.
- Click the ellipsis button (...) for the Script property. The Configure Functoid Script dialog box opens.
- In the Script type box, click Inline C#.
- In the Inline script buffer box, select and then delete the text.
- Copy the following code into the Inline script buffer text area, and then click OK.
public string ReplaceSpaces(string custnmbr)
{
custnmbr = custnmbr.Replace(" ","");
return custnmbr;
}
- On the Build menu, click Build MapsCRMGP.
Step 3: Publish the customized Crm_account_to_gp_customer.btm BizTalk map
In this step, you update the Crm_account_to_gp_customer.btm BizTalk map by using the Setting and Administration Tool on the server that is running the Microsoft Dynamics CRM Connector. To do this, follow these steps:
- Click Start, point to All Programs, point to Microsoft CRM Connector for Microsoft Dynamics GP, and then click Setting and Administration Tool.
- Click Administration, and then click Integration Server.
- Click the Customize Maps tab.
- Click Add Map.
- Locate and then open the Microsoft.MbsIntegration.MapsCRMGPCustom.dll file.
- In the Add New Map Web Page dialog box, click Select Map, and then click Microsoft.MbsIntegration.MapsCRMGP.crm_account_to_gp_customer. Then, follow these steps:
- In the Map description type box, type a description for the map.
- In the Event box, click Create.
- In the Source application box, click Microsoft CRM.
- In the Source entity box, click Account.
- In the Destination application box, click Microsoft Great Plains.
- In the Destination entity box, click Customer.
- Click Deploy Maps.
- Click OK.
- Click Start, point to All Programs, point to Administrative Tools, and then click Services.
- Restart the following services:
- BizTalkServerApplication
- MBSIntSendHost