INTEGRATE. Using Web Services for Microsoft Dynamics GP in Business Portal. Microsoft Dynamics GP. White Paper

Similar documents
Integrating Business Portal 3.0 with Microsoft Office SharePoint Portal Server 2003: A Natural Fit

Pipeliner CRM Phaenomena Guide Add-In for MS Outlook Pipelinersales Inc.

Customizing Remote Desktop Web Access by Using Windows SharePoint Services Stepby-Step

Pipeliner CRM Phaenomena Guide Sales Pipeline Management Pipelinersales Inc.

Microsoft Dynamics GP. Business Analyzer

User Document. Adobe Acrobat 7.0 for Microsoft Windows Group Policy Objects and Active Directory

Microsoft Dynamics GP. Workflow Installation Guide Release 10.0

Report Designer and Report Designer Add-In Installation Guide Version 1.0

Deploying the Workspace Application for Microsoft SharePoint Online

Adobe Acrobat 9 Deployment on Microsoft Windows Group Policy and the Active Directory service

AvePoint SearchAll for Microsoft Dynamics CRM

AvePoint Record Rollback for Microsoft Dynamics CRM

CRM Form to Web. Internet Lead Capture. Installation Instructions VERSION 1.0 DATE PREPARED: 1/1/2013

Lab Answer Key for Module 9: Active Directory Domain Services. Table of Contents Lab 1: Exploring Active Directory Domain Services 1

Configuring.NET based Applications in Internet Information Server to use Virtual Clocks from Time Machine

A SharePoint Developer Introduction

Adobe Acrobat 9 Deployment on Microsoft Systems Management

AvePoint SearchAll for Microsoft Dynamics CRM

Pipeliner CRM Phaenomena Guide Opportunity Management Pipelinersales Inc.

Business Portal for Microsoft Dynamics GP. Key Performance Indicators Release 10.0

Dell Recovery Manager for Active Directory 8.6. Quick Start Guide

WhatsUp Gold v16.2 Installation and Configuration Guide

Lab Answer Key for Module 11: Managing Transactions and Locks

Creating and Deploying Active Directory Rights Management Services Templates Step-by-Step Guide

Sage HRMS 2014 Sage Employee Self Service Tech Installation Guide for Windows 2003, 2008, and October 2013

Troubleshooting File and Printer Sharing in Microsoft Windows XP

Technical Brief for Windows Home Server Remote Access

Pipeliner CRM Phaenomena Guide Sales Target Tracking Pipelinersales Inc.

SELF SERVICE RESET PASSWORD MANAGEMENT BACKUP GUIDE

Windows SharePoint Services Installation Guide

Hands-On Lab: WSUS. Lab Manual Expediting WSUS Service for XP Embedded OS

SQL Server 2014 BI. Lab 04. Enhancing an E-Commerce Web Application with Analysis Services Data Mining in SQL Server Jump to the Lab Overview

Update and Installation Guide for Microsoft Management Reporter 2.0 Feature Pack 1

How to configure the DBxtra Report Web Service on IIS (Internet Information Server)

AvePoint Meetings for SharePoint Online. Configuration Guide

Dell Statistica Document Management System (SDMS) Installation Instructions

MadCap Software. Upgrading Guide. Pulse

Pipeliner CRM Phaenomena Guide Lead Management Pipelinersales Inc.

Windows Azure Pack Installation and Initial Configuration

Pipeliner CRM Phaenomena Guide Administration & Setup Pipelinersales Inc.

CRM to Exchange Synchronization

ImageNow Interact for Microsoft SharePoint Installation, Setup, and User Guide

Mindjet on-premise Installation Instructions for Microsoft SharePoint 2007

Installation and Deployment

Sage 300 ERP Sage CRM 7.1 Integration Guide

Improving Performance of Microsoft CRM 3.0 by Using a Dedicated Report Server

Microsoft Dynamics GP Release

Millennium Drive. Installation Guide

Windows Server Update Services 3.0 SP2 Step By Step Guide

AvePoint Tags 1.1 for Microsoft Dynamics CRM. Installation and Configuration Guide

Archive Attender Version 3.5

Lab Answer Key for Module 1: Installing and Configuring Windows Server Table of Contents Lab 1: Configuring Windows Server

Item Audit Log 2.0 User Guide

CRM to Exchange Synchronization

Dell Statistica Statistica Enterprise Installation Instructions

Management Reporter Integration Guide for Microsoft Dynamics GP

Mobility Services Platform Software Installation Guide

DocAve for Office 365 Sustainable Adoption

A SharePoint Developer Introduction. Hands-On Lab. Lab Manual HOL8 Using Silverlight with the Client Object Model C#

Microsoft Dynamics NAV 2013 R2 Release Notes Follow-up

SharePoint Password Change & Expiration 3.0 User Guide

StarWind iscsi SAN & NAS: Configuring HA File Server on Windows Server 2012 for SMB NAS January 2013

BusinessObjects Enterprise XI Release 2

ACT! by Sage. Premium for Workgroups 2007 (9.0) Administrator s Guide to the ACT! Reader Utility

Spotlight Management Pack for SCOM

Microsoft SQL Server Installation Guide

File and Printer Sharing with Microsoft Windows

Enabling Remote Management of SQL Server Integration Services

Mobility Services Platform 3.1 Software Installation Guide

SOLARWINDS ORION. Patch Manager Evaluation Guide for ConfigMgr 2012

Configuring Your Firewall for Client Access in Professional Edition

Pipeliner CRM Phaenomena Guide Getting Started with Pipeliner Pipelinersales Inc.

Installing the ASP.NET VETtrak APIs onto IIS 5 or 6

Creating IBM Cognos Controller Databases using Microsoft SQL Server

Installing DocAve 6 with Windows Clustering

Business Portal for Microsoft Dynamics GP Field Service Suite

Interact for Microsoft Office

User Guide. DocAve Lotus Notes Migrator for Microsoft Exchange 1.1. Using the DocAve Notes Migrator for Exchange to Perform a Basic Migration

SQL Server 2005 Reporting Services (SSRS)

Step-by-Step Guide for Microsoft Advanced Group Policy Management 4.0

Pipeliner CRM Phaenomena Guide Importing Leads & Opportunities Pipelinersales Inc.

StarWind iscsi SAN Software: Using StarWind with MS Cluster on Windows Server 2008

Juris Installation / Upgrade Guide

MicrosoftDynam ics GP TenantServices Installation and Adm inistration Guide

How To Install Outlook Addin On A 32 Bit Computer

CONFIGURING IIS WEB APPLICATIONS FOR USE WITH TIME MACHINE

Disaster Recovery. Websense Web Security Web Security Gateway. v7.6

Deploying Remote Desktop Web Access with Remote Desktop Connection Broker Step-by- Step Guide

Lab Answer Key for Module 6: Configuring and Managing Windows SharePoint Services 3.0. Table of Contents Lab 1: Configuring and Managing WSS 3.

QuadraMed Enterprise Scheduling Combined Service Installation Guide. Version 11.0

Microsoft Dynamics GP. Engineering Data Management Integration Administrator s Guide

Microsoft SQL Server 2008 R2 Express Edition with Advanced Services Installation Guide

Deep Dive into SharePoint Provider Hosted Apps

CONFIGURING MICROSOFT SQL SERVER REPORTING SERVICES

The cloud server setup program installs the cloud server application, Apache Tomcat, Java Runtime Environment, and PostgreSQL.

StarWind iscsi SAN & NAS: Configuring HA Shared Storage for Scale- Out File Servers in Windows Server 2012 January 2013

TIBCO Spotfire Automation Services Installation and Configuration

Cloud Attached Storage

Lab 05: Deploying Microsoft Office Web Apps Server

SP Term Cloud Installation

Transcription:

INTEGRATE Microsoft Dynamics GP Using Web Services for Microsoft Dynamics GP in Business Portal White Paper How to use Visual Studio 2005 and Web Services for Microsoft Dynamics GP 10.0 to create a new Business Portal web part. Date: September 26, 2007

Table of Contents Introduction...3 Internet Information Services (IIS) configuration...3 Uninstall Web Services for Microsoft Dynamics GP:...3 Create a new web site:...4 Reinstall Web Services for Microsoft Dynamics GP:...4 Add the Microsoft Windows user to the BDC Administrator role:...5 Visual Studio 2005 Web Site custom application...6 Exposing the custom application in Business Portal...8 How to use Company Database ID in custom application...9 Microsoft Business Framework Method:...9 Office SharePoint Server Method:...9 2

Introduction This document provides the developer a sample solution that demonstrates how to add new functionality into Business Portal for Microsoft Dynamics GP 10.0. In this scenario, we use Visual Studio 2005 and Web Services for Microsoft Dynamics GP 10.0 to create a web part that creates Sales Quotes from the Sales Quote List page in Business Portal. The custom Enter Sales Quotes web part is shown below in the Sales Quote List page: Internet Information Services (IIS) configuration If Business Portal and Web Services for Microsoft Dynamics GP will be installed on the same web server, these programs need to be installed in their own web sites. The following steps describe how to move the web site for Web Services for Microsoft Dynamics GP to a new site. (For more information, refer to Knowledge Base article 920903). Uninstall Web Services for Microsoft Dynamics GP: 1. From the Start menu, choose Control Panel, and then choose Add or Remove Programs. 2. Select Web Services for Microsoft Dynamics GP, and then click Change. 3. Click Remove. Do not mark the Remove SQL Objects and Data check box. 4. Click Next. 3

Create a new web site: 1. From the Start menu, choose Administrative Tools, and then choose Internet Information Services (IIS) Manager. 2. Expand the local computer name in the left pane, and then right-click Web Sites. Choose New, and then choose Web Site. 3. In the Web Site Creation wizard, click Next. 4. On the Web Site Description page, enter a description for the site, such as "Web services." 5. Click Next. 6. On the IP Address and Port Settings page, enter a port number other than port 80. Alternatively, enter a host header, such as Web services. Note: Port 80 is the default port number for the Default Web Site. Only one web site can use a specific port number unless you specify a host header for the new site. That host header lets IIS correctly route requests to the appropriate sites. See the IIS documentation for more information about port numbers and host headers. 7. Click Next. 8. On the Web Site Home Directory page, enter the path of the folder in which you want to create the new web site. This folder can be in any location, or you can create a new folder. 9. Clear the Allow anonymous access to this web site check box. 10. Click Next. 11. On the Web Site Access Permissions page, mark the Read check box, the Run scripts check box, and the Execute check box. 12. Click Next to complete the wizard and to create the new web site. Reinstall Web Services for Microsoft Dynamics GP: 1. Reinstall Web Services for Microsoft Dynamics GP to the site that you created in the previous procedure. Use the installation procedure described in the Microsoft Dynamics GP Web Services Installation and Administration Guide. 2. Verify the new URL in a web browser. You can access the web site for Web Services for Microsoft Dynamics GP by using one of the following URLs, depending on whether you specified a port or a host header when you created the site: http://<computer_name:port>/dynamicsgpwebservices http://<host_header>/dynamicsgpwebservices 4

Add the Microsoft Windows user to the BDC Administrator role: The Business Data Catalog web parts in Business Portal use Web Services for Microsoft Dynamics GP. It is necessary to use the Dynamics Security Console to add the Windows user running the Application pool for the Business Portal web site into the BDC Administrator role. To determine the Application Pool for the Business Portal web site, right click on the web site and choose Properties, and then display the Home Directory tab. If you are not sure which web site is the Business Portal web site, click each web site to look for a virtual directory called BusinessPortal. To add the Windows user to the BDC Administrator role, complete the following steps: 1. Open the Dynamics Security Console on a computer where the console is installed. From the Start menu, choose Administrative Tools, and then choose Dynamics Security Console. 2. Select the Role Assignments node in the left pane of the Dynamics Security Console. 3. From the Action menu, choose Add. The Add Role Assignments window will appear. 4. In the Role list, select the BDC Administrator role. 5. Click Add Windows Users to add individual windows users to the role assignment. 6. Select the desired company or all companies and click OK to save the new role assignment. 5

Visual Studio 2005 Web Site custom application The custom application is an ASP.NET web site application created with Visual Studio 2005. A web reference in the project is made to the DynamicsGPService.asmx page to access the WSDL (Web Services Description Language) of the Dynamics GP Web Service. The web site application is made up of a simple Default.aspx page that has four text box controls, two button controls, and some labels. The Default.aspx page references a DataMgr class that handles calling the web service. The attached code is for the Default.aspx.cs and DataMgr.cs files. Note: To view attachments, you must be viewing this document in Adobe Reader 6.0 or later, or in the full version of Acrobat. Right-click the paperclip icon to the left of the desired file, and choose to open or save the file. Default.aspx.cs.txt DataMgr.cs.txt When it is time to publish the web site, make sure the following options are marked: Allow this precompiled site to be updatable Enable strong naming on precompiled assemblies Mark assemblies with AllowPartiallyTrustedCallerAttribute The following illustration shows the Publish Web Site window in Visual Studio 2005. (To view this window, choose Build from the Publish Web Site menu.) Steps for using the Strong Name tool to create a key file are located at http://msdn2.microsoft.com/enus/library/6f05ezxy(vs.80).aspx. It is necessary to follow these steps when publishing the web site so the web part will display correctly. Windows SharePoint Services 3.0 will need to trust the new assemblies that are generated from the Publish Web Site process. In addition to the Publish Web Site steps, you will need to add a new code group to the WSS_minimaltrust.config file, using the following steps: 1. From the Start menu, choose Administrative Tools, and then choose Microsoft.NET 2.0 Configuration. 2. Expand Runtime Security Policy, expand Machine, expand Code Groups, expand All Code, and then expand My_Computer_Zone. 3. Right-click My_Computer_Zone, and then choose New. 6

4. In the Create Code Group window, give the group a name such as WSStrongName. 5. Click Next. 6. In the Choose Condition Type window, click Strong Name, click Import, and then locate the.dll file that contains the digitally signed assembly. A public key appears on the window. 7. Click Next, click Existing Permission Set, and then click Full Trust. 8. Click Next. 9. Click Finish. This step creates a code group for that key. 10. Locate the C:\Windows\Microsoft.NET\Framework\v2.0.50727\CONFIG folder on the computer where you created the code group. 11. Open the Security.config file, and then copy the code group nodes that contain the new group. For example, a code group node resembles the following: version="1" PermissionSetName="FullTrust" Name="BPSDKStrongName" Description=""> version="1" PublicKeyBlob="00240000048000009400000006020000002400005253413100040000010001004DC871C3C1549 B921CA9417CF9FE423F0FBF8B98720EF7C8C1988945FF5B45D4934594201C9FE886F36B20C0976AFF63DCAC196 1E7287616AA7C79B97273F14CD659436A2FD3AEEBA048D3E01AE3A834F31615CA97B8FFEF03726C2D09F00014 692D63824E7328EBDD92C4E63FDB8F9A35B90AACBD6E2A1FC2D87B41B228F9BB"/> 12. Locate the C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\config folder, open the WSS_minimaltrust.config file, and then locate the following code group. version="1" PermissionSetName="FullTrust" Name="MBFStrongName" Description=""> version="1" PublicKeyBlob="0024000004800000940000000602000000240000525341310004000001000100B5FC90E7027F67 871E773A8FDE8938C81DD402BA65B9201D60593E96C492651E889CC13F1415EBB53FAC1131AE0BD333C5EE602 1672D9718EA31A8AEBD0DA0072F25D87DBA6FC90FFD598ED4DA35E44C398C454307E8E33B8426143DAEC9F59 6836F97C8F74750E5975C64E2189F45DEF46B2A2B1247ADC3652BF5C308055DA9"/> 13. Paste the code group nodes that you copied in step 11 into the WSS_minimaltrust.config file immediately after the code group that you located in step 12. This is a critical step. If the code group is not put in the correct location, the code and the Business Portal assemblies will not be trusted. 14. Save the WSS_minimaltrust.config file. 15. Copy the strong named assemblies to the Bin folder of the Business Portal web site and the aspx pages to the desired location. 7

Exposing the custom application in Business Portal Since the custom application allows a user to enter Sales Quotes, the location of the custom application will be on the Sales Quote List page under the Sales Center site. The custom application will be rendered in a Page Viewer web part. The default.aspx page will be located in the BusinessPortal virtual directory. The default location is at C:\Program Files\Microsoft Dynamics\Business Portal\Applications. The following screen shot illustrates the Page Viewer web part points to a new folder called SalesQuoteMgmt. The path is /BusinessPortal/Applications/SalesQuoteMgmt: A benefit of storing the custom application pages in the BusinessPortal virtual directory is the ability to leverage the Business Portal session information. In this example, the custom application is leveraging the user s Business Portal session to attain the company database ID and set the OrganizationKey of the Context object in the Dynamics GP Web Service call. The code files attached below provide examples of using the Microsoft Business Framework and Office SharePoint Server assemblies. The Office SharePoint Server assembly method can be used when Business Portal is installed in a Microsoft Office SharePoint Server environment. Note: To view attachments, you must be viewing this document in Adobe Reader 6.0 or later, or in the full version of Acrobat. Right-click the paperclip icon to the left of the desired file, and choose to open or save the file. MBFMethod.txt OSSMethod.txt 8

How to use Company Database ID in custom application Use the method appropriate for your installation type. Microsoft Business Framework Method: 1. Open the project using Visual Studio 2005. 2. In Solution Explorer, right-click on the project and choose Add Reference. 3. View the Browse tab and locate the Microsoft.BusinessFramework.dll. Click OK. (This assembly is located in the Bin folder of the Business Portal web site.) 4. Add the following using directives: using Microsoft.BusinessFramework using Microsoft.BusinessFramework.Entity; 5. Add the code from the MBFMethod.txt file to the class in the project. Notice that the CompanyKey of the Web Services is set to the value returned by the GetDBID() method. 6. Build and publish the web site application, following the recommendations in this document. Office SharePoint Server Method: 1. Open the project using Visual Studio 2005. 2. In Solution Explorer, right-click on the project and choose Add Reference. 3. View the Browse tab and locate the Microsoft.Office.Server.dll. Click OK. (The default location is C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\isapi) 4. Add the following using directive: using Microsoft.Office.Server.UserProfiles; 5. Add the code from the OSSMethod.txt file to the class in the project. Notice that the CompanyKey of the Web Services is set to the value returned by the GetDataBaseOSS() method. 6. Build and publish the web site application, following the recommendations in this document. 9

The information contained in this document represents the current view of Microsoft Corporation on the issues discussed as of the date of publication. Because Microsoft must respond to changing market conditions, this document should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information presented after the date of publication. This White Paper is for informational purposes only. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED, OR STATUTORY, AS TO THE INFORMATION IN THIS DOCUMENT. Complying with all applicable copyright laws is the responsibility of the user. Without limiting the rights under copyright, no part of this document may be reproduced, stored in or introduced into a retrieval system, or transmitted in any form or by any means (electronic, mechanical, photocopying, recording, or otherwise), or for any purpose, without the express written permission of Microsoft Corporation. Microsoft may have patents, patent applications, trademarks, copyrights, or other intellectual property rights covering subject matter in this document. Except as expressly provided in any written license agreement from Microsoft, the furnishing of this document does not give you any license to these patents, trademarks, copyrights, or other intellectual property. 2007 Microsoft Corporation. All rights reserved. Microsoft, the Microsoft Dynamics Logo, Microsoft Dynamics, SharePoint, Visual Studio, and Windows are either registered trademarks or trademarks of Microsoft Corporation in the United States and/or other countries. 10