5/24/2010

SharePoint 2010: Part 4: Preparing for 70-573 TS Microsoft SharePoint 2010, Application Development

 

Web parts are cool… Ask someone to name five features of SharePoint and they will almost always mention web parts. And the best thing, most of what you need to know about web parts is how to create ASP.NET 2.0 web parts.

 

Skills Being Measured:
Developing Web Parts and Controls (21%)

Create Web Parts

  • This objective may include but is not limited to: including properties, controls using Render vs. CreateChildControl, life cycle,  visual, standard Web Parts,  
  • This objective does not include: trivial case where developer uses Visual Web Part project template

Create connectable Web Parts

  • This objective may include but is not limited to: Implement consumer/provider interfaces

Debug Web Parts

  • This objective may include but is not limited to: ULS log, and event log, debug.log tracing, developer dashboard

Create and implement delegate controls

  • This objective may include but is not limited to: overriding existing controls with lower sequence, developing and using .ascx files

 

Notes:

 

Web Parts in General

If you have not worked with web parts before go and find any of the good books or online tutorials and videos on SharePoint 2007 web parts. Maybe start with this book: Inside Microsoft Windows SharePoint Services 3.0  or attend a good SharePoint 2007 or 2007/2010 dev class (like mine!).

What’s new in 2010?

  • Visual Web Parts
  • Debugging info from the Developer Dashboard
  • Using the templates and deploy options in Visual Studio 2010
  • Sandboxed Solutions (several web part restrictions)

Web Part Notes:

  • Know how to write code for custom connection interfaces, and the SharePoint interfaces
  • Know the difference between, and when you would use, System.Web.UI.WebControls.WebParts.WebPart (recommended) or Microsoft.SharePoint.WebPartPages.WebPart (mostly for backward compatibility)
  • Know what can be used in Sandboxed Solutions
    • Visual Web Parts = no
    • Microsoft.SharePoint.WebPartPages.WebPart = no
    • No Web Part connections
    • Asynchronous postbacks in Web Parts in sandboxed solutions are not supported and will not function
    • must have the AllowPartiallyTrustedCallers attribute set at the assembly level
  • Know how to deploy a web part as a Feature and as a Solution
  • Know all about Safe Controls
  • Know how to deploy using Visual Studio 2010 and how to manually deploy
  • Debugging
    • Debugging from Visual Studio on a local machine
    • Debugging from Visual Studio on a remote server
    • How to enable (and disable) the Developer Dashboard (STSADM, PowerShell and code)
    • Know where SharePoint logs things: Windows Event Logs, …\14\LOGS

Delegate Controls:

  • Basically a SharePoint control (<SharePoint:DelegateControl …/>) and a .Net user control ( *.ascx )
  • Need to know:
    • How to add SharePoint:DelegateControl to a page or a master page
    • How to deploy an ASCX control to ..\14\TEMPLATE\CONTROLS
    • How to associate an ASCX control to a DelegateControl (a Feature!)
    • How to declare a Safe Control in the web.config

 

Links:

Note: Many of these links include a link to the 2007 version of the documentation, so also check the 2007 version for “Community Comments”.

  • Web parts

MSDN: Web Parts in SharePoint Foundation
http://msdn.microsoft.com/en-us/library/ms476318.aspx

MSDN: System.Web.UI.WebControls.WebParts.WebPart
http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.webparts.webpart.aspx

MSDN: Microsoft.SharePoint.WebPartPages
http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.webpartpages.webpart.aspx

MSDN: AllowPartiallyTrustedCallersAttribute Class
http://msdn.microsoft.com/en-us/library/system.security.allowpartiallytrustedcallersattribute%28VS.90%29.aspx

  • Logging and Debugging

MSDN: What's New In Logging for SharePoint Foundation 2010
http://msdn.microsoft.com/es-es/library/ee535240.aspx

MSDN: Using the Developer Dashboard
http://msdn.microsoft.com/es-es/library/ff512745.aspx

MSDN: Using SPMonitoredScope
http://msdn.microsoft.com/en-us/library/ff512758.aspx

MSDN: Logging For SharePoint Developers
http://msdn.microsoft.com/en-us/library/ee535537.aspx

MSDN: Overview of Unified Logging System (ULS) Logging
http://msdn.microsoft.com/en-us/library/ff512738.aspx

  • Delegate Control

(2007)  MSDN: Delegate Control
http://msdn.microsoft.com/en-us/library/bb861966%28office.12%29.aspx

MSDN: Delegate Control
http://msdn.microsoft.com/en-us/library/ms463169.aspx

MSDN: DelegateControl Class
http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.webcontrols.delegatecontrol.aspx

 

 

How-to’s, Tutorials, etc.

 

Video: Module 1: Getting Started: Building Web Parts in SharePoint 2010
http://msdn.microsoft.com/en-us/sharepoint/ee513148.aspx

Video: Best Practices on Building SharePoint 2010 Web Parts with Visual Studio 2010
http://channel9.msdn.com/posts/funkyonex/Best-Practices-on-Building-SharePoint-2010-Web-Parts-with-Visual-Studio-2010/

Video: Advanced Web Part Development in SharePoint 2010 
http://channel9.msdn.com/posts/matthijs/Advanced-Web-Part-Development-in-SharePoint-2010/

Connect Web Parts in SharePoint 2010
http://msdn.microsoft.com/en-us/library/ff597538.aspx

Create Visual Web Parts for SharePoint 2010
http://msdn.microsoft.com/en-us/library/ff597539.aspx

 

How to: Customize a Delegate Control
http://msdn.microsoft.com/en-us/library/ms470880.aspx

 

.

No comments:

Note to spammers...

Spammers, don't waste your time... all posts are moderated. If your comment includes unrelated links, is advertising, or just pure spam, it will never be seen.