SlideShare una empresa de Scribd logo
1 de 19
Descargar para leer sin conexión
Alerts!
Creating alerts using the SP 2010 UI
Improvements, custom WCF services
and jQuery
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar




Session Breakdown
 Introduction (Brief)
  There a couple of things I “prepared earlier” … a brief explanation

 WCF
  Building a custom WCF service for SharePoint 2010
  The focus will not be what the service does but how to wire it up

 jQuery
  Instead of using the ASP.NET Ajax / Script Manager lets talk to the WCF
  service with jQuery

 SharePoint 2010 UI Utilities – Status Bar, Modal Dialog and Notifications
  The UI glue to show the information to users
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar




Introduction
 The Alert architecture
      A SharePoint List – the alert storage
      A custom WCF Service – the basic business objects / logic and
       communication mechanism
      jQuery – asynchronous data retrieval (on the client)
      SP.UI.Status – the presentation layer
WCF
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar




WCF
 Can build SOAP, REST or Data Services
 Supports dynamic configuration using factories. SharePoint 2010
  provides 3 factories:

 Service Type                      Service Factory                       Description
 SOAP service                      MultipleBaseAddressBasicHttpBindingS Basic HTTP binding must be used,
                                   erviceHostFactory                    which creates endpoints for a service
                                                                        based on the basic HTTP binding.
 REST Service                      MultipleBaseAddressWebServiceHostF    The service factory creates endpoints
                                   actory                                with Web bindings.
 ADO.NET Data Service              MultipleBaseAddressDataServiceHostF   A data service host factory can be used.
                                   actory
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar




Custom WCF Service in SharePoint 2010
 Can’t be deployed by a sandbox solution

 WCF isn’t 100% supported in SharePoint project templates
    Create a separate WCF Service Library and copy the files into the SharePoint
     project
    Add references to System.ServiceModel and System.Runtime.Serialization
    The service declaration (.svc) needs to be added to list of files processed for
     replaceable tokens
     http://msdn.microsoft.com/en-us/library/ee231545.aspx

 Create Alert class that represents our alerts for serialization/data
  transfer
      Alert { Title, Description, Link, Colour }
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar




Custom WCF Service in SharePoint 2010
 Make the service ASP.NET compatible
    using System.ServiceModel.Activation

     [AspNetCompatibilityRequirements(RequirementsMode =
     AspNetCompatibilityRequirementsMode.Required)]

 Make the service REST capable
    using System.ServiceModel.Web

     [WebGet(UriTemplate = "/Alert", BodyStyle = WebMessageBodyStyle.Bare,
     ResponseFormat = WebMessageFormat.Json)]

 Using MultipleBaseAddressWebServiceHostFactory because its a REST
  service (sort of)
DEMO: Custom WCF Build
jQuery
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar




jQuery
 We could use ASP.NET AJAX but … we won’t


 We will use jQuery to call our WCF web service
      jQuery has built in support for ajax and JSON

       jQuery.ajax()
       jQuery.getJSON()
User Interface Utilities – SP.UI
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar




The OOTB UI Improvements in 2010
 SP.UI.Notify
      addNotification(), Notify(), removeNotification()


 SP.UI.Status
      addStatus(), appendStatus(), removeAllStatus(), removeStatus(),
       setStatusPriColor(), Status(), updateStatus()


 SP.UI.ModalDialog.showModalDialog(options)
      options is a JavaScript literal of the properties to pass this method
     e.g. var options = { url: “http://sharepoint.com” }
DEMO: How to use jQuery and SP.UI
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar




Resources
 WCF Services in SharePoint Foundation 2010
  http://msdn.microsoft.com/en-us/library/ff521586.aspx


 Creating a Custom WCF Service in SharePoint Foundation
  http://msdn.microsoft.com/en-us/library/ff521581.aspx

 jQuery ajax and JSON
  http://api.jquery.com/jQuery.ajax/
  http://api.jquery.com/jQuery.getJSON/
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar




Resources
 SP.UI.Notify
  http://msdn.microsoft.com/en-us/library/ff408137.aspx

 SP.UI.Status
  http://msdn.microsoft.com/en-us/library/ff412058.aspx

 SP.UI.ModalDialog
  http://msdn.microsoft.com/en-us/library/ff408909.aspx
  http://msdn.microsoft.com/en-us/library/ff411351.aspx

 Enabling Intellisense in Visual Studio
  http://msdn.microsoft.com/en-us/library/ff798328.aspx
SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar




Nick Hadlee
SharePoint Consultant at Intergen

Blog:    nickhadlee.wordpress.com
Twitter: @nickhadlee
Questions
Thank you to our Sponsors




M S C O M M U N IT IE S

Más contenido relacionado

La actualidad más candente

Presentazione Sharepoint 2010
Presentazione Sharepoint 2010Presentazione Sharepoint 2010
Presentazione Sharepoint 2010Decatec
 
SharePoint Connections Coast to Coast Overview of Enterprise Content Management
SharePoint Connections Coast to Coast Overview of Enterprise Content ManagementSharePoint Connections Coast to Coast Overview of Enterprise Content Management
SharePoint Connections Coast to Coast Overview of Enterprise Content ManagementIvan Sanders
 
Jordan Remix - SharePoint 2010
Jordan Remix - SharePoint 2010Jordan Remix - SharePoint 2010
Jordan Remix - SharePoint 2010Jordan Remix
 
3 lists, libraries, share point designer, business intelligence
3   lists, libraries, share point designer, business intelligence3   lists, libraries, share point designer, business intelligence
3 lists, libraries, share point designer, business intelligenceicdesktop
 
Configuring SharePoint 2013 for BI scenarios
Configuring SharePoint 2013 for BI scenariosConfiguring SharePoint 2013 for BI scenarios
Configuring SharePoint 2013 for BI scenariosSPC Adriatics
 
SharePoint Connections Coast to Coast Business Intelligence Solutions with Sh...
SharePoint Connections Coast to Coast Business Intelligence Solutions with Sh...SharePoint Connections Coast to Coast Business Intelligence Solutions with Sh...
SharePoint Connections Coast to Coast Business Intelligence Solutions with Sh...Ivan Sanders
 
Introduction to JSLink in 2013
Introduction to JSLink in 2013Introduction to JSLink in 2013
Introduction to JSLink in 2013Sparkhound Inc.
 
Chris givens building custom service applications
Chris givens building custom service applicationsChris givens building custom service applications
Chris givens building custom service applicationsChris Givens
 
SharePoint Saturday Sacramento Business Intelligence with SharePoint 2010
SharePoint Saturday Sacramento  Business Intelligence with SharePoint 2010SharePoint Saturday Sacramento  Business Intelligence with SharePoint 2010
SharePoint Saturday Sacramento Business Intelligence with SharePoint 2010Ivan Sanders
 
1.2 introduction
1.2   introduction 1.2   introduction
1.2 introduction icdesktop
 
SharePoint 2010 as a Development Platform, Ayman El-Hattab MVP
SharePoint 2010 as a Development Platform, Ayman El-Hattab MVPSharePoint 2010 as a Development Platform, Ayman El-Hattab MVP
SharePoint 2010 as a Development Platform, Ayman El-Hattab MVPAyman El-Hattab
 
AX2012 Technical Track - Entreprise portal, Czesia Langoswka
AX2012 Technical Track -  Entreprise portal, Czesia LangoswkaAX2012 Technical Track -  Entreprise portal, Czesia Langoswka
AX2012 Technical Track - Entreprise portal, Czesia Langoswkadynamicscom
 
WKDNUG SP2010 Development Presentation
WKDNUG SP2010 Development PresentationWKDNUG SP2010 Development Presentation
WKDNUG SP2010 Development PresentationRob Wilson
 
Ax 2012 enterprise portal development
Ax 2012 enterprise portal developmentAx 2012 enterprise portal development
Ax 2012 enterprise portal developmentMoutasem Al-awa
 
Practical businerss intelligence in share point 2013
Practical businerss intelligence in share point 2013Practical businerss intelligence in share point 2013
Practical businerss intelligence in share point 2013Ivan Sanders
 
Configuração de um Portal Sharepoint 2007 e Funcionalidades de Apoio
Configuração de um Portal Sharepoint 2007 e Funcionalidades de ApoioConfiguração de um Portal Sharepoint 2007 e Funcionalidades de Apoio
Configuração de um Portal Sharepoint 2007 e Funcionalidades de ApoioComunidade NetPonto
 
SharePoint 2013 Sneak Peek
SharePoint 2013 Sneak PeekSharePoint 2013 Sneak Peek
SharePoint 2013 Sneak PeekShailen Sukul
 
SharePoint Saturday NYC - Business Intelligence
SharePoint Saturday NYC - Business IntelligenceSharePoint Saturday NYC - Business Intelligence
SharePoint Saturday NYC - Business IntelligenceIvan Sanders
 
KPI Roll-Up In SharePoint 2007
KPI Roll-Up In SharePoint 2007KPI Roll-Up In SharePoint 2007
KPI Roll-Up In SharePoint 2007PathToSharePoint
 

La actualidad más candente (20)

Presentazione Sharepoint 2010
Presentazione Sharepoint 2010Presentazione Sharepoint 2010
Presentazione Sharepoint 2010
 
SharePoint Connections Coast to Coast Overview of Enterprise Content Management
SharePoint Connections Coast to Coast Overview of Enterprise Content ManagementSharePoint Connections Coast to Coast Overview of Enterprise Content Management
SharePoint Connections Coast to Coast Overview of Enterprise Content Management
 
Jordan Remix - SharePoint 2010
Jordan Remix - SharePoint 2010Jordan Remix - SharePoint 2010
Jordan Remix - SharePoint 2010
 
3 lists, libraries, share point designer, business intelligence
3   lists, libraries, share point designer, business intelligence3   lists, libraries, share point designer, business intelligence
3 lists, libraries, share point designer, business intelligence
 
Configuring SharePoint 2013 for BI scenarios
Configuring SharePoint 2013 for BI scenariosConfiguring SharePoint 2013 for BI scenarios
Configuring SharePoint 2013 for BI scenarios
 
SharePoint Connections Coast to Coast Business Intelligence Solutions with Sh...
SharePoint Connections Coast to Coast Business Intelligence Solutions with Sh...SharePoint Connections Coast to Coast Business Intelligence Solutions with Sh...
SharePoint Connections Coast to Coast Business Intelligence Solutions with Sh...
 
Introduction to JSLink in 2013
Introduction to JSLink in 2013Introduction to JSLink in 2013
Introduction to JSLink in 2013
 
Chris givens building custom service applications
Chris givens building custom service applicationsChris givens building custom service applications
Chris givens building custom service applications
 
SharePoint Saturday Sacramento Business Intelligence with SharePoint 2010
SharePoint Saturday Sacramento  Business Intelligence with SharePoint 2010SharePoint Saturday Sacramento  Business Intelligence with SharePoint 2010
SharePoint Saturday Sacramento Business Intelligence with SharePoint 2010
 
1.2 introduction
1.2   introduction 1.2   introduction
1.2 introduction
 
SharePoint 2010 as a Development Platform, Ayman El-Hattab MVP
SharePoint 2010 as a Development Platform, Ayman El-Hattab MVPSharePoint 2010 as a Development Platform, Ayman El-Hattab MVP
SharePoint 2010 as a Development Platform, Ayman El-Hattab MVP
 
AX2012 Technical Track - Entreprise portal, Czesia Langoswka
AX2012 Technical Track -  Entreprise portal, Czesia LangoswkaAX2012 Technical Track -  Entreprise portal, Czesia Langoswka
AX2012 Technical Track - Entreprise portal, Czesia Langoswka
 
Sharepoint2
Sharepoint2Sharepoint2
Sharepoint2
 
WKDNUG SP2010 Development Presentation
WKDNUG SP2010 Development PresentationWKDNUG SP2010 Development Presentation
WKDNUG SP2010 Development Presentation
 
Ax 2012 enterprise portal development
Ax 2012 enterprise portal developmentAx 2012 enterprise portal development
Ax 2012 enterprise portal development
 
Practical businerss intelligence in share point 2013
Practical businerss intelligence in share point 2013Practical businerss intelligence in share point 2013
Practical businerss intelligence in share point 2013
 
Configuração de um Portal Sharepoint 2007 e Funcionalidades de Apoio
Configuração de um Portal Sharepoint 2007 e Funcionalidades de ApoioConfiguração de um Portal Sharepoint 2007 e Funcionalidades de Apoio
Configuração de um Portal Sharepoint 2007 e Funcionalidades de Apoio
 
SharePoint 2013 Sneak Peek
SharePoint 2013 Sneak PeekSharePoint 2013 Sneak Peek
SharePoint 2013 Sneak Peek
 
SharePoint Saturday NYC - Business Intelligence
SharePoint Saturday NYC - Business IntelligenceSharePoint Saturday NYC - Business Intelligence
SharePoint Saturday NYC - Business Intelligence
 
KPI Roll-Up In SharePoint 2007
KPI Roll-Up In SharePoint 2007KPI Roll-Up In SharePoint 2007
KPI Roll-Up In SharePoint 2007
 

Similar a SharePoint Alerts with WCF and jQuery

Building+restful+webservice
Building+restful+webserviceBuilding+restful+webservice
Building+restful+webservicelonegunman
 
Building RESTful Services with WCF 4.0
Building RESTful Services with WCF 4.0Building RESTful Services with WCF 4.0
Building RESTful Services with WCF 4.0Saltmarch Media
 
WCF Data Services - Bandung Charity Event - 2010
WCF Data Services  - Bandung Charity Event - 2010WCF Data Services  - Bandung Charity Event - 2010
WCF Data Services - Bandung Charity Event - 2010Andri Yadi
 
Web API or WCF - An Architectural Comparison
Web API or WCF - An Architectural ComparisonWeb API or WCF - An Architectural Comparison
Web API or WCF - An Architectural ComparisonAdnan Masood
 
Parallelminds.asp.net web service
Parallelminds.asp.net web serviceParallelminds.asp.net web service
Parallelminds.asp.net web serviceparallelminder
 
ADO.NET Data Services
ADO.NET Data ServicesADO.NET Data Services
ADO.NET Data Servicesukdpe
 
Jax ws
Jax wsJax ws
Jax wsF K
 
Session 7 - Integrating share point with silverlight firestarter
Session 7 - Integrating share point with silverlight firestarterSession 7 - Integrating share point with silverlight firestarter
Session 7 - Integrating share point with silverlight firestarterMithun T. Dhar
 
Integration of Web Service Stacks in an Esb
Integration of Web Service Stacks in an EsbIntegration of Web Service Stacks in an Esb
Integration of Web Service Stacks in an EsbWen Zhu
 
Reusing Existing Java EE Applications from SOA Suite 11g
Reusing Existing Java EE Applications from SOA Suite 11gReusing Existing Java EE Applications from SOA Suite 11g
Reusing Existing Java EE Applications from SOA Suite 11gGuido Schmutz
 
Novidades Do Asp.Net 4 E Do Visual Studio 2010
Novidades Do Asp.Net 4 E Do Visual Studio 2010Novidades Do Asp.Net 4 E Do Visual Studio 2010
Novidades Do Asp.Net 4 E Do Visual Studio 2010Rodrigo Kono
 
Oracle JET and WebSocket
Oracle JET and WebSocketOracle JET and WebSocket
Oracle JET and WebSocketandrejusb
 
Spsdc what's new in share point 2013 workflow
Spsdc   what's new in share point 2013 workflowSpsdc   what's new in share point 2013 workflow
Spsdc what's new in share point 2013 workflowamitvasu
 
Web service through cxf
Web service through cxfWeb service through cxf
Web service through cxfRoger Xia
 
Usability AJAX and other ASP.NET Features
Usability AJAX and other ASP.NET FeaturesUsability AJAX and other ASP.NET Features
Usability AJAX and other ASP.NET FeaturesPeter Gfader
 
HTTP Whiteboard - OSGI Compendium 6.0 - How web apps should have been! - R Auge
HTTP Whiteboard - OSGI Compendium 6.0 - How web apps should have been! - R AugeHTTP Whiteboard - OSGI Compendium 6.0 - How web apps should have been! - R Auge
HTTP Whiteboard - OSGI Compendium 6.0 - How web apps should have been! - R Augemfrancis
 
WCF LOB SDK from CodeMastery
WCF LOB SDK from CodeMasteryWCF LOB SDK from CodeMastery
WCF LOB SDK from CodeMasteryclineer
 
SharePoint 2010 Architecture - TechEd Brasil 2010
SharePoint 2010 Architecture - TechEd Brasil 2010SharePoint 2010 Architecture - TechEd Brasil 2010
SharePoint 2010 Architecture - TechEd Brasil 2010Michael Noel
 

Similar a SharePoint Alerts with WCF and jQuery (20)

Building+restful+webservice
Building+restful+webserviceBuilding+restful+webservice
Building+restful+webservice
 
Building RESTful Services with WCF 4.0
Building RESTful Services with WCF 4.0Building RESTful Services with WCF 4.0
Building RESTful Services with WCF 4.0
 
WCF Data Services - Bandung Charity Event - 2010
WCF Data Services  - Bandung Charity Event - 2010WCF Data Services  - Bandung Charity Event - 2010
WCF Data Services - Bandung Charity Event - 2010
 
Web API or WCF - An Architectural Comparison
Web API or WCF - An Architectural ComparisonWeb API or WCF - An Architectural Comparison
Web API or WCF - An Architectural Comparison
 
Parallelminds.asp.net web service
Parallelminds.asp.net web serviceParallelminds.asp.net web service
Parallelminds.asp.net web service
 
ADO.NET Data Services
ADO.NET Data ServicesADO.NET Data Services
ADO.NET Data Services
 
Jax ws
Jax wsJax ws
Jax ws
 
Session 7 - Integrating share point with silverlight firestarter
Session 7 - Integrating share point with silverlight firestarterSession 7 - Integrating share point with silverlight firestarter
Session 7 - Integrating share point with silverlight firestarter
 
Wcf remaining
Wcf remainingWcf remaining
Wcf remaining
 
Integration of Web Service Stacks in an Esb
Integration of Web Service Stacks in an EsbIntegration of Web Service Stacks in an Esb
Integration of Web Service Stacks in an Esb
 
Reusing Existing Java EE Applications from SOA Suite 11g
Reusing Existing Java EE Applications from SOA Suite 11gReusing Existing Java EE Applications from SOA Suite 11g
Reusing Existing Java EE Applications from SOA Suite 11g
 
Novidades Do Asp.Net 4 E Do Visual Studio 2010
Novidades Do Asp.Net 4 E Do Visual Studio 2010Novidades Do Asp.Net 4 E Do Visual Studio 2010
Novidades Do Asp.Net 4 E Do Visual Studio 2010
 
Oracle JET and WebSocket
Oracle JET and WebSocketOracle JET and WebSocket
Oracle JET and WebSocket
 
Spsdc what's new in share point 2013 workflow
Spsdc   what's new in share point 2013 workflowSpsdc   what's new in share point 2013 workflow
Spsdc what's new in share point 2013 workflow
 
Web service through cxf
Web service through cxfWeb service through cxf
Web service through cxf
 
Usability AJAX and other ASP.NET Features
Usability AJAX and other ASP.NET FeaturesUsability AJAX and other ASP.NET Features
Usability AJAX and other ASP.NET Features
 
Web API with ASP.NET MVC by Software development company in india
Web API with ASP.NET  MVC  by Software development company in indiaWeb API with ASP.NET  MVC  by Software development company in india
Web API with ASP.NET MVC by Software development company in india
 
HTTP Whiteboard - OSGI Compendium 6.0 - How web apps should have been! - R Auge
HTTP Whiteboard - OSGI Compendium 6.0 - How web apps should have been! - R AugeHTTP Whiteboard - OSGI Compendium 6.0 - How web apps should have been! - R Auge
HTTP Whiteboard - OSGI Compendium 6.0 - How web apps should have been! - R Auge
 
WCF LOB SDK from CodeMastery
WCF LOB SDK from CodeMasteryWCF LOB SDK from CodeMastery
WCF LOB SDK from CodeMastery
 
SharePoint 2010 Architecture - TechEd Brasil 2010
SharePoint 2010 Architecture - TechEd Brasil 2010SharePoint 2010 Architecture - TechEd Brasil 2010
SharePoint 2010 Architecture - TechEd Brasil 2010
 

Último

A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 

Último (20)

A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 

SharePoint Alerts with WCF and jQuery

  • 1. Alerts! Creating alerts using the SP 2010 UI Improvements, custom WCF services and jQuery
  • 2. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar
  • 3. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar Session Breakdown  Introduction (Brief) There a couple of things I “prepared earlier” … a brief explanation  WCF Building a custom WCF service for SharePoint 2010 The focus will not be what the service does but how to wire it up  jQuery Instead of using the ASP.NET Ajax / Script Manager lets talk to the WCF service with jQuery  SharePoint 2010 UI Utilities – Status Bar, Modal Dialog and Notifications The UI glue to show the information to users
  • 4. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar Introduction  The Alert architecture  A SharePoint List – the alert storage  A custom WCF Service – the basic business objects / logic and communication mechanism  jQuery – asynchronous data retrieval (on the client)  SP.UI.Status – the presentation layer
  • 5. WCF
  • 6. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar WCF  Can build SOAP, REST or Data Services  Supports dynamic configuration using factories. SharePoint 2010 provides 3 factories: Service Type Service Factory Description SOAP service MultipleBaseAddressBasicHttpBindingS Basic HTTP binding must be used, erviceHostFactory which creates endpoints for a service based on the basic HTTP binding. REST Service MultipleBaseAddressWebServiceHostF The service factory creates endpoints actory with Web bindings. ADO.NET Data Service MultipleBaseAddressDataServiceHostF A data service host factory can be used. actory
  • 7. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar Custom WCF Service in SharePoint 2010  Can’t be deployed by a sandbox solution  WCF isn’t 100% supported in SharePoint project templates  Create a separate WCF Service Library and copy the files into the SharePoint project  Add references to System.ServiceModel and System.Runtime.Serialization  The service declaration (.svc) needs to be added to list of files processed for replaceable tokens http://msdn.microsoft.com/en-us/library/ee231545.aspx  Create Alert class that represents our alerts for serialization/data transfer  Alert { Title, Description, Link, Colour }
  • 8. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar Custom WCF Service in SharePoint 2010  Make the service ASP.NET compatible  using System.ServiceModel.Activation [AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Required)]  Make the service REST capable  using System.ServiceModel.Web [WebGet(UriTemplate = "/Alert", BodyStyle = WebMessageBodyStyle.Bare, ResponseFormat = WebMessageFormat.Json)]  Using MultipleBaseAddressWebServiceHostFactory because its a REST service (sort of)
  • 11. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar jQuery  We could use ASP.NET AJAX but … we won’t  We will use jQuery to call our WCF web service  jQuery has built in support for ajax and JSON jQuery.ajax() jQuery.getJSON()
  • 13. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar The OOTB UI Improvements in 2010  SP.UI.Notify  addNotification(), Notify(), removeNotification()  SP.UI.Status  addStatus(), appendStatus(), removeAllStatus(), removeStatus(), setStatusPriColor(), Status(), updateStatus()  SP.UI.ModalDialog.showModalDialog(options)  options is a JavaScript literal of the properties to pass this method e.g. var options = { url: “http://sharepoint.com” }
  • 14. DEMO: How to use jQuery and SP.UI
  • 15. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar Resources  WCF Services in SharePoint Foundation 2010 http://msdn.microsoft.com/en-us/library/ff521586.aspx  Creating a Custom WCF Service in SharePoint Foundation http://msdn.microsoft.com/en-us/library/ff521581.aspx  jQuery ajax and JSON http://api.jquery.com/jQuery.ajax/ http://api.jquery.com/jQuery.getJSON/
  • 16. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar Resources  SP.UI.Notify http://msdn.microsoft.com/en-us/library/ff408137.aspx  SP.UI.Status http://msdn.microsoft.com/en-us/library/ff412058.aspx  SP.UI.ModalDialog http://msdn.microsoft.com/en-us/library/ff408909.aspx http://msdn.microsoft.com/en-us/library/ff411351.aspx  Enabling Intellisense in Visual Studio http://msdn.microsoft.com/en-us/library/ff798328.aspx
  • 17. SharePoint Saturday New Zealand – WCF, jQuery and the SP Status Bar Nick Hadlee SharePoint Consultant at Intergen Blog: nickhadlee.wordpress.com Twitter: @nickhadlee
  • 19. Thank you to our Sponsors M S C O M M U N IT IE S