Docstoc
EXCLUSIVE OFFER FOR DOCSTOC USERS
Try the all-new QuickBooks Online for FREE.  No credit card required.

SharePointFest Visual Web parts - SharePoint 2010 Now

Document Sample
SharePointFest Visual Web parts - SharePoint 2010 Now Powered By Docstoc
					           Developing SharePoint 2010 Web
                          Visual Web Parts




Created by Gary Newman
MCSE, MCT, CCNA, MCDBA, MCAD, MCDST, MCTS Server 2008,
MCTS SharePoint Development and Administration, MODL
MOUS Master Instructor, CIW Instructor
   Visual Studio 2010 Improvements for
    SharePoint
   Developing Standard Web Parts
   Developing Visual Web Parts
   Demo: Creating SharePoint 2010 Web Parts
    by Using Visual Studio 2010




                                    www.ameriteach.com
   Built-in Deployment tools
   Better Debugging
   More SharePoint Aware
   Create a Visual Web Part




                                www.ameriteach.com
   Difference between a Standard web part and
    Visual Web parts.
   Adding Standard Web Parts to Visual Studio
    2010 Projects




                                    www.ameriteach.com
   User's Perspective
   Administrator's Perspective
   Developer's Perspective
    ◦ Class that inherits from
      System.Web.UI.WebControls.WebParts.WebPart




                                         www.ameriteach.com
   Web Part is a SharePoint 2010 project item
   Class is pre-configured with common using statements
    ◦ Typical namespaces used in ASP.NET Web Parts
    ◦ SharePoint namespaces
   Adding additional namespaces
   Class is pre-configured with an override for the most
    common method
    ◦ CreateChildControls
   Adding controls to the programmatic control tree
   Overriding additional methods or properties


                                                www.ameriteach.com
   What Is a Visual Web Part?
   Adding Visual Web Parts to Visual Studio
    2010 Projects
   Developing User Interfaces for Visual Web
    Parts
   Developing Code for Visual Web Parts
   Deploying Visual Web Parts from Visual
    Studio

                                      www.ameriteach.com
   User's Perspective
    ◦ Web Part
   Administrator's Perspective
    ◦ ASP.NET user control in the SharePoint file system
   Developer's Perspective
    ◦ ASP.NET User Control with UI designers
    ◦ Standard Web Part that loads the user control at run
      time


                                            www.ameriteach.com
   Visual Web Part is a SharePoint 2010 project type,
    and a SharePoint project item type
   ASP.NET user control is added to the project
    ◦ Designer and markup (.ASCX)
    ◦ Code-behind file (.CS or .VB)
   Standard Web Part is added to the project
    ◦ Includes Page.LoadControl() and Controls.Add()
      statements
   Adding SharePoint namespaces to the user control


                                            www.ameriteach.com
www.ameriteach.com
    Design view
    Source view
    Split view
    Adding user interface elements
     ◦ Toolbox
     ◦ Markup
...
// Add UI Elements
<asp:TreeView ID="overviewTree"
  runat="server"
  ShowLines="true"
  EnableViewState="true">
</asp:TreeView>
                                      www.ameriteach.com
   As simple as deploying a standard Web Part
   Visual Web Part restrictions
    ◦ No out of box Sandboxed solutions




                                          www.ameriteach.com
   Creating a Visual Web Part by Using Visual
    Studio 2010




                                      www.ameriteach.com
   Please take time to fill out the eval to help
    make the next one better and maybe win a
    iPad!!




                                        www.ameriteach.com

				
DOCUMENT INFO
Shared By:
Categories:
Tags:
Stats:
views:7
posted:9/3/2011
language:English
pages:14