SharePoint 2010 Web Part expose web service? - web-services

Is it possible for a SharePoint 2010 Web Part to expose a web service (WCF?)?
I want a Web Part to send emails if a certain condition is met. The web part should be hit every 15 mins via a call initiated from a custom in-house scheduler.
Cheers

A web part is just a visual component. It can expose a web service. However, custom web services can be created and deployed to SharePoint where you can access data from a site (a list maybe) and add custom logic to send the email.
Here's a good guide on how to deploy web services to SharePoint.

Related

Integration between custom system and Crm Dynamics 2016 Online

I'm working on Dynamics since about 1 year, and I'm working on "on premise" environments, and I don't know very much about online solutions.
I should now integrate 2 systems through webservice, and one of them involves Microsoft Dynamics CRM Online 2016.
What I'm trying to accomplish is that the custom systems sends data to the CRM Online through webservice.
I've read I just can't deploy my webservice and my logic as I've always done (separate web application that receives a Json or a XML through web services and works on CRM entities through the SDK).
So, do I need a separate machine to receive the XML and working on the CRM through the SDK?
In some posts I learn a little about Azure, but I don't know if it could be a nice solution. Should I get a virtual machine and then install IIS? Will my web app be visible by the custom system and able to work on the CRM online? Do I need a different service?
Thanks in advance and sorry for the confusion, it's the first time I'm trying to make CRM Online communicate with the outside.
So if I understand correctly your approach is 'custom system <=> your WS <=> CRM Online 2016
I've read I just can't deploy my webservice and my logic as I've always done (separate web application that receives a Json or a XML through web services and works on CRM entities through the SDK).
In CRM Online you don't have access to machine that CRM stands on so no folders, no inetmgr, no deploy.
So, do I need a separate machine to receive the XML and working on the CRM through the SDK?
Yes.
Should I get a virtual machine and then install IIS?
It doesn't have to be new virtual machine. It could be for example machine that custom system stands on ofc. if it can be configured to have access to the internet.
Will my web app be visible by the custom system and able to work on the CRM online?
It is matter of configuration of NAT, firewall etc.
Do I need a different service?
What service do you reffer here?

How to consume asp.net web service in SharePoint site?

I have asp.net web service application created in VS 2010. I created this web service using ASP.NET Web Service Application template in VS 2010. My InfoPath form consumes my webservice. However to fill out my IP form, I first have to make sure I run my web service, otherwise I get errors like cannot connect to the webservice.
How can I make sure my web services are properly deployed to my SharePoint site that hosts infoPath form services? Please let me know the necessary steps. If my web services are deployed to my SharePoint site then there's no need to manually run my asp.net web service in the browser everytime I need to fill out the form. Thanks.
Here's the error message I got when I tried to browse my custom web service deployed to layouts folder:
http://abcd/_layouts/WebServiceDemo/MyCustomWebService.asmx
I couldn't find relevant message in 14-->LOGS. Any idea what's causing this? Thanks.
My own analysis: Please visit the web.config inside LAYOUTS folder and set Customerros to Off to get more meaningful error message.
I Googled "How to consume asp.net web service in SharePoint site".
The third hit was Walkthrough: Creating a Custom ASP.NET (ASMX) Web Service in SharePoint 2010. The post shows how to create, deploy and consume the service.

Web Parts and Web Services

I am working with Visual Studio 2008 and SharePoint 2007. I have created a web part , a web user control that pulls data from a web service (binding a DropDownlist from web service) has been wrapped in my Web Part. When I deploy my web part it doesn't show me the data pulled from web service (Empty DropDownList). please advice how to use web parts that interacts with external web services.
Thanks a lot.
http://support.microsoft.com/kb/826994
This should have everything you need.

Want to create a approval workflow from window phone 7

we are integrating sharepoint 2010 with window phone 7.
we want to create a interface on phone using which we can create a approval workflow on sharepoint site.
Is there any inbuilt sharepoint web service available??
If not what other options we have....
if we try to create our own web service for this , than what should be the functionality of that web service
Your question is too broad but, yes, SharePoint has web services.

Using a Web Service to access data outside MOSS using AD for authentication

So here is the scenario:
I have a MOSS 2007 box and I want my clients to be able to access a SharePoint site via the internet. I am told that I will be using an IPA and AD for authentication. However I have a DB outside of SharePoint that holds various business data and I want to use Web Services to access the data, manipulate it, and send it back to SharePoint via web parts.
The issue is that, from what I understand, I am going to have to authenticate the AD user every time a request to the Web Service happens. Obviously I dont want to do this every time because they have already authenticated to get onto the site, however I do want each call to have some form of security so its not open calls to my db. I do plan on having other applications access this service outside of SharePoint, so I dont want to have to reinstall the service for each application or even again.
Has anyone had to perform this task or something similar or do you have any suggestions on how to do this?
Thank you in advance and happy coding!
Why not just deploy the webservice to Sharepoint using a Sharepoint solution and a Feature.
That way it will be running under the sharepoint app pool and all authentication is done by sp.
Edit:
Seeing that SharePoint should not be in "control" (as stated in the comment), you should create the webservice, and run the application it's under in as using Windows Authentication. IMHO you should create a WCF Service. The, using the information found in this article you make the Service authenticate users against the AD usergroups they are in. see the "Security: Authentication" section of the article.
Then in Visual Studio you create a webpart and add a service reference to the project, pointing to your newly created Service. Have the webpart perform the needed logic (i.e. display data etc.)
Deploy the webpart to SharePoint using a SharePoint solution (.wsp files, created with WSPBuilder). Google for SharePoint + wspbuilder + tutorials. The solution should contain 1 feature to deploy the webpart. WSPBuilder integrates with VS and allows for the creation of WSPBuilde project. add a webpart feature item to the project (it will create the xml (deployment related) and code file for the webpart.