Web Parts: Web Parts are modular units of information that consist of a title bar, a frame, and content. Web Parts allow you to create personalized user interfaces by simply dragging individual Web Parts onto a Web page. Each Web Part makes certain content or data available on a page, and may also make it possible for the user to work with or modify that data through the browser. By using the Web Parts located on pages in a SharePoint site, users can access data from both inside and outside their organizations.
Web Part zones: A Web Part zone is a Web Part container that can be configured to control the organization and format of the Web Parts that are contained in it. Web Part zones make it possible not only to group and arrange Web Parts, but also to customize them in the browser and to control who can modify them there. Each of the individual Web Parts on a Web Part Page may or may not be located within a Web Part zone: Web Part Pages: When they are in use, Web Parts reside on a Web Part Page, which is a special type of Microsoft ASP.NET (ASPX) page that contains at least one Web Part or Web Part zone. When you use Office SharePoint Designer 2007 to add a Web Part or Web Part zone to a blank ASPX page, that page automatically becomes a Web Part Page and acquires the necessary page directive that identifies it as a Web Part Page.
********************************************
A Developer's Introduction to Web Parts Web Parts Infrastructure
The new Web Parts infrastructure builds on ASP.NET by providing a .NET object model that contains classes that derive from and extend ASP.NET classes. Additional classes and database objects handle storage (in Microsoft SQL Server(tm) or MSDE) and site administration. Web Parts are ASP.NET server controls. To create a new type of Web Part, you create an ASP.NET custom control. However, unlike standard ASP.NET controls, which are added to Web form pages by programmers at design time, Web Parts are intended to be added to Web Part Zones on Web Part Pages by users at run time. Depending on which site groups users are assigned to, and depending on the rights assigned to those groups, users can have varying levels of freedom to modify Web Parts and Web Part Pages. They can make changes that apply to all the users of a shared page, or they can make changes that apply only when they view the page. In many ways, Web Parts blur the traditional distinction between design time and run time. The run-time experience of a user working with Web Parts in a browser is similar to the design-time experience of a Microsoft Visual Basic® programmer adding controls to a form and setting their properties. Web page designers can also build Web Part Pages in Microsoft Office FrontPage® 2003, which is able to render Web Parts in the design environment. Web Parts rely heavily on Windows SharePoint Services to support: 1. Creation of new sites and new pages 2. Management of the user roster for a site 3. Storage of Web Part customizations, including shared and personal property settings 4. Administration of site backups and storage limits 5. A scalable architecture that can handle thousands of sites and millions of users 6. Assignment of users to customizable site groups Note Microsoft SharePoint Products and Technologies no longer rely on role-based security for assigning rights and permissions to users. Instead, SharePoint Products and Technologies use site groups and cross-site groups to assign rights and permissions to users. Site groups are custom security groups that apply to a specific Web site. Cross-site groups are custom security groups that apply to more than one Web site. For more information, see Microsoft Windows SharePoint Services Help. In turn, SharePoint Products and Technologies rely on Web Parts to provide configurable and extensible user interfaces. Adding Web Parts to a Web Part Page Windows SharePoint Services provides four types of galleries that can contain Web Parts: 1. Virtual Server gallery 2. gallery 3. Web Part Page gallery 4. Online gallery The Virtual Server Gallery lists Web Parts that are available to all sites on the server. The Gallery contains Web Parts that are available to a particular site. By default, when you run Stsadm.exe to install a Web Part, Stsadm.exe adds the Web Part to the Virtual Server Gallery. More information about how to work with the administration tools available in Windows SharePoint Services to populate the Web Site gallery is available later in this article. A Web Part Page gallery contains Web Parts that are already added to the current page. This may seem paradoxical at first. Why would you need to add a Web Part that is already added to the page? The reason this is useful is that you can add a Web Part to a page and then close the Web Part. To close a Web Part, click the arrowhead on the right side of the Web Part title bar, and then click Close. A closed Web Part is no longer visible on the page, but it is still a member of the Web Part Page gallery for that page. The Web Part is still associated with the page by an entry in the configuration database of the server running Windows SharePoint Services, which also stores any shared or personalized property settings for the Web Part. You can add a Web Part to a page, personalize it extensively, close it, and then later add it back to the page with the personalization intact. To bring back a closed Web Part, select it from the Web Part Page gallery. Installing to the GAC for Full Trust If you give your Web Part assembly a strong name, you have one more option for elevating its trust level. You can install your assembly in the Global Assembly Cache so it automatically executes with full trust. The reason for this becomes clear if you inspect the policy files for Windows SharePoint Services. Even the Wss_minimaltrust.config file includes the following code group: When you use the Stsadm.exe utility to install a Web Part .cab file for an assembly that has a strong name, you can use the globalinstall command line switch to install it to the GAC, as follows: Stsadm.exe -o addwppack -filename path_to_Web_Part.cab file -globalinstall You can also manually install a strong-named Web Part assembly to the GAC by dragging the .dll file for the Web Part to the following special folder: local_drive:\Windows\Assembly A special Wpresources folder location is used for all Web Parts that are installed to the GAC: local_drive:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\wpresources One advantage of using URLs based on the Wpresources directory is that the Web Part infrastructure automatically looks for your files in the appropriate location, depending on whether a Web Part is installed to the bin directory for a virtual server or to the GAC. However, relying on the GAC is another example of an easy but potentially dangerous way to add permissions to your Web Part, because Web Parts installed in the GAC always run with full trust. A better practice is to give your code only the permissions that it needs, and no more. Web Parts installed to the GAC also automatically become available to every virtual server on that computer, which you may not want. When you install to a Bin directory, you can limit your Web Part to a single virtual server and limit the permissions available to your Web Part.
Ref: http://msdn.microsoft.com/en-us/library/dd583154(office.11).aspx
What is a Web Part zone? A Web Part zone is a Web Part container that can be configured to control the organization and format of the Web Parts contained in it. Web Part zones make it possible not only to group and arrange Web Parts but also to customize them in the browser and to control who can modify them there. Each of the individual Web Parts on a Web Part Page may or may not be located within a Web Part zone: Web Parts located in a Web Part zone When a Web Part is located inside a Web Part zone, the Web Part properties are stored in the content database in Microsoft Windows SharePoint Services 3.0, not in the ASPX page. By inserting a Web Part inside a zone, you make it possible for users to interact with or modify that Web Part through the browser. Web Parts not located in a Web Part zone When a Web Part is not located inside a Web Part zone, the Web Part properties are stored in the ASPX page and not in the content database in Windows SharePoint Services 3.0. By inserting a Web Part without enclosing it in a zone, you allow users to view the Web Part, but you prevent them from interacting with or modifying the Web Part through the browser. This can be useful if you do not want users to be able to make any changes, either to the Web Part or to the way that it is displayed on the page. You can think of Web Parts, Web Part zones, and Web Part Pages as nested containers. The Web Parts themselves contain the data that you want to view and perhaps to change or interact with. The Web Part zones are optional subcontainers within the Web Part Page, each of which contains one or more Web Parts - making it possible to group and arrange those Web Parts on the page, to customize them while viewing them in the browser, and to specify who has permissions to view and to customize them in that way. And the Web Part Page contains both the Web Parts and the Web Part zones.
Ref: http://office.microsoft.com/en-us/sharepointdesigner/HA101513941033.aspx
Walkthrough: Creating a Basic SharePoint Web Part
This programming task includes the steps for creating a basic custom Windows SharePoint Services Web Part. It is a simple Web Part that allows you to change the Web Part's Title property, which is a Windows SharePoint Services WebPart base class property that sets the text in the title bar of the Web Part. Important: Beginning with Windows SharePoint Services 3.0, the Windows SharePoint Services Web Part infrastructure is built on top of the Microsoft ASP.NET 2.0 Web Part infrastructure and Web Parts that derive from the ASP.NET WebPart class are completely supported in Windows SharePoint Services. You should create ASP.NET Web Parts whenever possible. For more information about choosing the best Web Part base class from which to derive, see Developing Web Parts in Windows SharePoint Services in the Windows SharePoint Services Software Development Kit (SDK). For more information about ASP.NET Web Parts, see the Web Parts Control Set Overview in the ASP.NET documentation. Prerequisites Microsoft Visual Studio 2005 Windows SharePoint Services 3.0
Ref: http://msdn.microsoft.com/en-us/library/ms452873.aspx
Walkthrough: Creating a Basic Web Part
This walkthrough provides the steps for creating a basic custom Web Part that can be added to your Web Part Pages. It is a simple Web Part that allows the user to define a custom message to be displayed inside the Web Part. This Web Part will derive from the ASP.NET 2.0 Web Part class, which is the recommended practice for Windows SharePoint Services. Note that this walkthrough describes how to create a Web Part without the Visual Studio Extensions for Windows SharePoint Services. For more information about ASP.NET Web Parts, see the following ASP.NET documentation: ASP.NET QuickStart Tutorials and ASP.NET Web Parts Controls. Note: You can also develop your Web Parts by using the Visual Studio Extensions for Windows SharePoint Services. By using these extensions, you can greatly reduce the work involved in creating and deploying your Web Parts. The extensions require development in a server environment, and offer the following benefits: Automatic generation of your solution package Automatic generation of the WebPart XML file Ability to deploy Web Parts directly from inside Visual Studio to your Web site For guidance on using the extensions or to download extensions for Visual Studio 2005 or Visual Studio 2008, see Windows SharePoint Services 3.0 Tools: Visual Studio 2005 Extensions User Guide, Version 1.1 Windows SharePoint Services 3.0 Tools: Visual Studio Extensions, Version 1.1 Windows SharePoint Services 3.0 Tools: Visual Studio Extensions, Version 1.2 Prerequisites Windows SharePoint Services 3.0 Visual Studio 2005
Ref: http://msdn.microsoft.com/en-us/library/ms415817.aspx
Creating Custom Enterprise Search Web Parts in SharePoint Server 2007
With Enterprise Search in Microsoft Office SharePoint Server 2007, you can customize the look and functionality of Search Center pages and Web Parts from the browser. To make customizations that are not possible through the browser, you can create a custom Web Part that uses the Query object model to execute queries against the search component. This Office Visual How To article demonstrates creating a custom Enterprise Search Web Part in Office SharePoint Server 2007.
Ref: http://msdn.microsoft.com/en-us/library/bb871647.aspx
Creating Custom Web Parts for Project Server 2007
A Web Part is a modular unit of information that has a single purpose and is a basic building block of a Web Part Page. Project Web Access uses many Microsoft Office Project Server 2007 Web Parts and can be easily extended with custom Web Parts. Web Parts in Windows SharePoint Services 3.0 improve upon earlier versions of Web Part technologies. You can use Windows SharePoint Services 2.0 Web Parts and ASP.NET 2.0 Web Parts. You can also use Web Parts in shared Web Part Page documents in a project workspace or team site. The shared documents are stored and managed on a computer running Windows SharePoint Services that is provisioned by Project Server. This Office Visual How To article shows the creation of a custom Web Part for Project Server 2007 that you can use to display the upcoming tasks for a specified project. The code presented in this article is based on the "No PWA Reference" Web Part sample that is included in the Microsoft Office Project 2007 SDK download.
Ref: http://msdn.microsoft.com/en-us/library/bb851478.aspx
SharePoint Products and Technologies: Creating Custom Web Part Page Templates Sample http://www.microsoft.com/downloads/details.aspx?FamilyId=48B2C899-DB2C-4A93-AA95-AF4A37FA8AE8&displaylang=en
SharePoint Server 2007 Sample: Web Part That Calls Excel Web Services
Ref: http://www.microsoft.com/downloads/details.aspx?familyid=2c5919e4-0757-4db1-9798-e0e4032f12a8&displaylang=en
(3rd Party) SharePoint 2007 Flash Animation Web Part Please Note that 3rd Party Code/Tools are NOT supported by Microsoft.
No comments:
Post a Comment