Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Microsoft SharePoint 2010 Development with Visual Studio 2010 Expert Cookbook

You're reading from   Microsoft SharePoint 2010 Development with Visual Studio 2010 Expert Cookbook Develop, debug, and deploy business solutions for SharePoint applications using Visual Studio 2010 with this book and ebook.

Arrow left icon
Product type Paperback
Published in Sep 2011
Publisher Packt
ISBN-13 9781849684583
Length 296 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Balaji Kithiganahalli Balaji Kithiganahalli
Author Profile Icon Balaji Kithiganahalli
Balaji Kithiganahalli
Arrow right icon
View More author details
Toc

Table of Contents (15) Chapters Close

Microsoft SharePoint 2010 Development with Visual Studio 2010: Expert Cookbook
Credits
About the Author
Acknowledgement
About the Reviewers
www.PacktPub.com
Preface
1. Lists and Event Receivers FREE CHAPTER 2. Workflows 3. Advanced Workflows 4. List Definitions and Content Types 5. Web Parts 6. Web Services and REST 7. Working with Client Object Model Index

Creating a custom activity for a sandboxed solution


Even with the limited capabilities of sandboxed solutions, you can still develop custom activities that can be used in SharePoint designer without making changes to web.config or adding the .ACTIONS file to the root folder.

In this recipe, we will create a custom activity that can be deployed in a sandboxed environment. This activity will create an event in the calendar for a given date.

Getting ready

The concepts of custom activities need to be understood before following this recipe. Hence you should have completed the previous recipe successfully.

How to do it...

  1. Create an empty SharePoint project called SandboxedActivity and make sure to select deploy as a sandboxed solution.

  2. Add a class file and name it SandboxActivity. Also make sure to change the access modifier to public.

  3. Add the following code using statements to the class:

    using System.Collections;
    using Microsoft.SharePoint;
    using Microsoft.SharePoint.UserCode;
    using Microsoft.SharePoint...
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image