SharePoint Web Part using Dynamics CRM 2011 web services - web-services

I'm want to create some SharePoint 2010 Web Part which could retrieve data from Dynamics CRM 2011 web service. I can not add references to the CRM dlls because the web part will be using assemblies of .Net 3.5 version, and I get a troubles when I try to deploy my Web Part with assemblies of .Net 4.0 added.
Can I use these Web services without adding CRM assemblies?

You could use a service reference which targets the WSDL-endpoint. See http://msdn.microsoft.com/en-us/library/gg509052.aspx for more information.

Related

Create web services and APIs to query and CRUD processes from Microsoft Dynamics CRM

We have been developing MS Dynamics CRM - as our central application - for 1+ years with MS Dynamics SDK and dedicated tools to query from MS Dynamics CRM database.
We have also one mobile application and web site which we need to get information from our MS Dynamics CRM database. I don't want to use MS's own Dynamics CRM SDK to create this data communication with our web site and mobile application.
Is it possible to create a fully independent (such nodejs, laravel etc.) to directly query and CRUD processes from MS Dynamics CRM database, without using MS own tools/SDKs?
Thank you

Microsoft Dynamics 2013 and Microsoft Dynamics 365 works with same Rest API?

I am working on an extension for dynamics.
Here i want to use dynamics api.
One client uses Microsoft Dynamics 365 (Rest API) and
another client uses Microsoft Dynamics 2013.
Can i use same api to serve both the clients ?
Currently i am using api's from
https://learn.microsoft.com/en-us/dynamics365/customer-engagement/developer/webapi/web-api-functions-actions-sample-csharp
Will it work for Microsoft Dynamics 2013?
The Dynamics 365 Web API did not exist in CRM 2013, so you cannot use that for both purposes.
Instead you can use the Organization Service (also called the CRM 2011 endpoint). The behavior of this endpoint has been relatively consistent (with some minor changes to how e.g. updates should be made) from CRM 2013 to D365.
Be aware that the Organization Service will be removed at some point in the future, but currently works just fine:
The Web API is intended to replace the CRM 2011 endpoint, also known
as the SOAP endpoint, for accessing the Dynamics 365 organization web
service and other provided web services.
As of the release of Microsoft Dynamics CRM Online 2016 Update 1 and
Microsoft Dynamics CRM 2016 Service Pack 1 (8.1.0), the CRM 2011
endpoint has been deprecated. The 2011 endpoint will be removed some
time after the release of Dynamics 365 version 9.
No you cannot use D365 Web API for both.
I found this is useful for CRM 2013.
http://xrmenterprise.com/2013/09/microsoft-dynamics-crm-2013-client-api-cheat-sheet/

Create a web service that is hosted on IIS 6.0 and Asp.net 2.0

I need to create a web service that will be hosted by a website running IIS 6.0 and Asp.net 2.0. I have never created a web service before now. I have Visual Studio 2008.
What options do I have for creating the service.
Can I create the service using WCF and still have it hosted on Asp.net 2.0?
Do I have to specify any specific properties when I build it so that the service will run on 2.0?
Or must I use ASMX to build the web service?
I have tried building a service in VS2008 both as ASMX and WCF but I am unable to Add Web Reference to either type of service from VS2008 when I am testing how to consume it. I'm certain my lack of experience with Web Services is a big factor, but the more I read, the more uncertain I am of what technology I can use to create this IIS 6.0, Asp.net 2.0 hosted service.
WCF was introduced in .NET 3.5, so you need to use the legacy ASMX technology. Create an ASMX service, and use "Add Web Reference" to consume it. The first time you try that, you'll need to use "Add Service Reference", and then to click the "Advanced" button and then the "Add Web Reference" button. After that, "Add Web Reference" will be available as a command.

SharePoint Web Services client that supports 2010 and 2007,

Is it possible to support both SharePoint Web Services 2010 and 2007 from the same web services client? or will they need different clients.
How different are the web services from previous versions of SharePoint Web Services. I can't seem to find any examples of supporting multiple versions of SharePoint Web Services when implementing a client.
As far as I know all the SP 2007 Web services work the same in SP 2010.
What's new in SP 2010 is the RESTful service (listdata.svc) which is, according to Microsoft, the preferred way to access list data (rather than Lists.asmx).
Take a look at the namespaces of the service contracts (in the WSDL). If they are the same then the services should be compatible.

Hosting existing web services in sharepoint 2010

I have a set of web services coded. Need to create an application combining some of share point 2010 features plus functionalities of my services. I was thinking of deploying the services as a part of the sharepoint application (in a virtual directory) i'm building [Not hosting as a separate application elsewhere since I do not want the service calls(script calls) to end up cross-domain]
Is this the right approach. If yes, what needs to be ensured while making my services a part of a sharepoint application using a virtual directory
You can use the SPDev tool to generate the SharePoint web service disco.aspx and wsdl.aspx files:
SPDev.exe -o GenWS -url http://Central-Administration-URL -asmx CustomWS.asmx
Then deploy all needed assemblies to GAC and copy the .asmx, disco.aspx, wsdl.aspx files to the 14 hive\ISAPI folder.
I don't think you can have path other than _vti_bin (or _vti_adm if deployed the service to the 14 hive\ADMISAPI folder), but you can deploy the web services to a subfolder and use URL like http://Site/_vti_bin/CustomDotNetWebServices/CustomWS.asmx.
SharePoint 2010 supports custom services - both ASP.NET and WCF ones:
Walkthrough: Creating a Custom ASP.NET Web Service
Creating a Custom WCF Service in SharePoint Foundation