1 / 27

The Ribbon UI and Custom Actions in SharePoint 2010

The Ribbon UI and Custom Actions in SharePoint 2010. Geoff Varosky December 11, 2012. About me. Geoff Varosky Jornata Managing Consultant, Senior Architect, Senior Developer, Director of Evangelism Co-Founder Boston Area SharePoint Users Group Co-Organizer SharePoint Saturday Boston

keiran
Download Presentation

The Ribbon UI and Custom Actions in SharePoint 2010

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. The Ribbon UI and Custom Actions in SharePoint 2010 Geoff Varosky December 11, 2012

  2. About me • Geoff Varosky • Jornata • Managing Consultant, Senior Architect, Senior Developer, Director of Evangelism • Co-Founder Boston Area SharePoint Users Group • Co-Organizer SharePoint Saturday Boston • Blog – www.SharePointYankee.com • Email – geoff@varosky.com • Twitter – @gvaro • LinkedIn & Facebook gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  3. agenda • Introducing the Ribbon UI • Demo • What are Custom Actions? • Demo • Resources • Q&A gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  4. Introducing the ribbon ui gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  5. What are custom actions? gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  6. What are custom actions? • Anything that can be put into an HREF anchor tag or “link” <a href=“CUSTOMACTION”>linkylinky</a> gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  7. What are custom actions? • Bits of XML <CustomAction Id=“MyCustomAction” Location=“Microsoft.SharePoint.SiteSettings … /> • Links <CustomAction …> <UrlActionUrl=“http://www.foo.com” /> </CustomAction> • JavaScript <CustomAction …> <UrlActionUrl=“javascript:DoSomething();” /> </CustomAction> • Code Behind <CustomAction … ControlAssembly=“MyCode, Version=1.0.0.0, Culture=neutral, PublicKeyToken=63316a326e123aec"ControlClass=“MyCode.Class“ /> gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  8. What are custom actions? • Can be bound to… • Lists • Tasks, Document Libraries, Custom, etc. gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  9. What are custom actions? • Can be bound to… • File Types • By Extension - .docx, .pl, .foo, .bar gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  10. What are custom actions? • Can be bound to… • Content Types • Tasks, Documents, Custom • All (0x) • http://go.gvaro.net/bbYxRy • Programmatic Identifiers • Tasks List (107) • Content Types (0x) gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  11. Building custom actions • SharePoint Designer 2010 • Build Custom Actions • List Item Menu (Context Menu) • List View, Edit, Display Forms • Visual Studio 2010 • Import from WSP file • Add functionality • Package • Deploy gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  12. Urlaction tokens • ~site • Site (Web) • ~sitecollection • Site Collection • {ItemId} • GUID representation of the current item • {ItemUrl} • URL of the current item • {ListId} • {ListURL} • {RecurrenceId} gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  13. (CustomAction) Anatomy 101 <CustomAction ContentTypeId = "Text" ControlAssembly = "Text" ControlClass = "Text" ControlSrc = "Text" Description = "Text" GroupId = "Text" Id = "Text" ImageUrl = "Text" Location = "Text" RegistrationId = "Text" RegistrationType = "Text" RequireSiteAdministrator = "TRUE" | "FALSE" Rights = "Text" Sequence = "Integer" ShowInLists = "TRUE" | "FALSE" ShowInReadOnlyContentTypes = "TRUE" | "FALSE" ShowInSealedContentTypes = "TRUE" | "FALSE" Title = "Text"> <URLAction URL=“” /> <CommandUI></CommandUI> </CustomAction>

  14. (CustomAction) Anatomy 101 • Id (optional) • Specifies a unique identifier for custom action • May be a GUID or a unique term • Example: DeleteWeb • GroupID(optional) • Identifies the unique group that this element is contained in • Example: SiteTasks

  15. (CustomAction) Anatomy 101 • Location (optional) • Specifies the location for this custom action • Example: Microsoft.SharePoint.SiteSettings • RegistrationType(optional) • Specifies the list, item content type, file type, or programmatic identifier that this action is associated with • Example: List

  16. (CustomAction) Anatomy 101 • RegistrationId(optional) • Specifies the registration attachment for a per-item action • Example (List Identifier – Task List): 107 • {$ListId:Lists/Tasks;} • (http://snipurl.com/ntd5g) • Title (required) • Specifies the name of your action • Example: DeleteWeb

  17. (CustomAction) Anatomy 101 • Description (optional) • Longer description for action which is shown as a tooltip or sub-description (where applicable) for the action • Sequence (optional) • The order in which your action will appear. • If not specified, displayed in the order it is read by SharePoint by Feature and by order in element listing (XML).

  18. Urlaction tokens • {ListId} • GUID representation of the list • {SiteUrl} • References the URL of the SPWeb context the action is called from • {RecurrenceId} • Unsupported in context menus • http://go.gvaro.net/bHaqaQ gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  19. resources • Custom Actions Articles on my blog • Creating Custom Actions with SharePoint Designer • Default List Type IDs • Deploying Custom Actions Across All List Types • Custom Actions in SharePoint 2007 • SPBasePermissions Enumeration (Rights) • And more! • http://go.gvaro.net/dZS9NJ gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  20. resources • MSDN • Custom Action Definition Schema • CommandUIDefintions, Extensions, Handlers • CustomAction, CustomActionGroup, HideCustomAction • Default Locations and IDs • http://go.gvaro.net/9q0QV2 • Eric Kraus • Listing all Custom Actions in the Farm with PowerShell • http://go.gvaro.net/bD7OHm gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  21. resources • WictorWilén • Creating Custom Ribbon Extensions • Part 1 - http://go.gvaro.net/aFUwBW • Part 2 - http://go.gvaro.net/aGlydC • Using JavaScript + Custom Actions to navigate Document Libraries • http://go.gvaro.net/h2w8mN gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  22. Questions? gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  23. Boston area sharepointug • Meets 2nd Wednesday/month • 6-8PM • Microsoft N.E.R.D. (Cambridge) • BostonSharePointUG.org • Twitter: @BASPUG / #BASPUG gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  24. Questions? gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

  25. About me • Geoff Varosky • Jornata • Managing Consultant, Senior Architect, Senior Developer, Director of Evangelism • Co-Founder Boston Area SharePoint Users Group • Co-Organizer SharePoint Saturday Boston • Blog – www.SharePointYankee.com • Email – geoff@varosky.com • Twitter – @gvaro • LinkedIn & Facebook gvarosky@jornata.com | @gvaro | www.sharepointyankee.com | www.jornata.com | @JornataLLC

More Related