Friday, July 22, 2005

Custom Sharepoint View

Let's see about creating a new View. Let us say that we want the Announcements List to appear in alphabetical order, running from A-Z.

If we click "Home" at the top-left corner of Windows Sharepoint Services we get to the homepage. Pick the Announcement List and then "Modify" as shown earlier.

Now, we're going to create a new Windows Sharepoint Services view called "Alpha". Scroll to the bottom of the page and select "Create New View".
Windows Sharepoint Services allows you to have three types of view..
  • the "Standard View" that we will use
  • a "Datasheet View" if you have Microsoft Office 2003
  • and a "Calendar View" which is good for event-type lists.

Select "Standard View". The next page asks you for a View Name. This will appear on the left hand side of the completed list. Type "Alpha" as this will be the name of the view.

Scroll down to the section called "Sort". There's a drop-down list that shows the available columns. We want the Title, since we'll be sorting by this field.

Below that is a set of buttons that allow you to select A-Z or Z-A sort order. We'll select A-Z.
Scroll to the bottom and Click the "OK" button.

Congratulations - You've made your First Custom View

Pop up to the Homepage and Select Announcements. Notice that there is now a second View available - the one you just created.

Click the link. Depending on the number of items in that list, you should see that the list is in alphabetical order. If you have only one item you should pop in a few more to prove it!

Your next challenge - create a few more views and explore the power of Views in Windows Sharepoint Services.

Building A Sharepoint View

A view lets us see Sharepoint Lists in different ways.

Consider the Sharepoint Announcements List we looked at earlier. We could have one view that shows only the last 5 items, or to show only items with a certain configuration.

Or perhaps show the items in alphabetical order.

Each of these are separate Sharepoint views. Each list has a "Default" view that is shown when the list is selected from the homepage.

Let's look at the Announcements List as an example.

If you open go the the Sharepoint list and select the "Modify settings and columns" link on the left side. Once this page has opened scroll to the bottom section titled "Views". This list has only one view - called "All Items". Click on the link and we'll see how this view is defined.

Sidebar

Some Lists are created with a number of Views. The Announcement is one of the simplest and has only the one.

But we'll change that soon.


Scroll down the view and notice the details. It shows

  • what Columns of the list are shown on the view. This view should show "Attachments", "Title" and "Modified "
  • The Sort order of the items. This view shows that the list will be sorted by "Modified" date and descending; so the most recent entry will be at the top of the list.
    The Filter allows you to hide or show items depending on some criteria. None are specified by default.
  • Grouping allows you to collect the items together using certain characteristics. A Staff List, for example, may be grouped by department.
  • Totals, Style and Limit are advanced features and will be covered later.

So, now you know how a View is constructed, lets take a look in the next Section: Custom Views