A Table of Contents for Your Site

Continuing on the theme from the last two weeks, I am going to take a look at another web part that is infrequently used, at least on the web sites that I work with. We use the Site Navigation feature out of the box for navigating between pages on a site and even to add custom links to pages and sites outside of our site. We also find the Site Navigation feature lets us build pseudo-hierarchies by adding header entries and links that serve as a fly-out to the header. But there is another way to provide navigation around a site. That is with the Table of Contents Web Part.

The Table of Contents web part lets me display all of the pages and sites that branch off the current site. The key advantage to this web part is that I can display up to three site levels (the current level and two nested sub-site levels) on a single page. It also gives me some built-in formatting capabilities to change the way the Table of Contents is rendered on the page ranging from vertical orientation to a horizontal orientation and several hybrid types in between. So let’s take a look at this web part.

Like other SharePoint web parts, I have to add the Table of Contents web part to a page on my site. This may mean that I have to first create the page where I want to place the Table of Contents. Then I can edit the page and going to the Insert ribbon and select the Web Part button from the Web Parts group. In SharePoint 2010, the Table of Contents web part can be found in the Default category as shown in the figure below. However, in SharePoint 2013, it was moved to the Content Rollup category which actually makes some sense.

After select the Table of Contents web part, click the Add button on the bottom right of the dialog. After adding the web part to the page, SharePoint provides a default view of the site. This view displays pages and sub-sites off the current site as shown below or it may only display sub-sites and their pages. In either case, I can easily modify the properties to control where the Table of Contents begins.

As with all web parts, I can edit the properties by hovering over the header to display the down-pointing caret on the right side of the header. This is the web part menu. I click on it to open the menu and select: Edit Web Part. The properties panel for the web part appears to the right of the page. You may need to scroll to the right and up the page to find it depending on the size of your page. The most interesting properties and the ones I will focus on appear in the top section of the panel. There are three sections: Content, Presentation, and Organization as shown in the following figure. Each has a box with a plus sign in it in. To open each section to view and modify its properties, click on the plus sign in the box to the left of the section name.

The following figure shows the properties found in the Content section. The first property identifies the site where the Table of Contents will begin. Note that you can either enter the URL or you can select it by clicking on the Browse button.

The second property identifies how many sub-site levels you want the Table of Contents to include. The maximum is three levels. There is also a check box where you can identify whether the site where you are beginning the Table of Contents should be included or whether to only include sub-sites under the current site and their pages.

Finally, this section has three check boxes where you can select whether you want to show pages (or just the sub-sites in the Table of Contents. You can also choose whether you want to display hidden pages or hidden sites. I suppose if you need to see everything in a site, you might check these two boxes, but most times I would guess that they were hidden for a reason.

The second section lets me modify some of the presentation features of the web part beginning with a header for the web part. Note that this is not the same as the web part Title that appears in the chrome of the web part. In fact, you may turn off the chrome and use this property to place a header at the top of the table of contents.

You can also modify the style of the header. The figure below shows the pre-defined styles available for the header.

You can also define the number of columns to divide the content area into. You can also modify the styles for the other levels. This will affect the sub-site entries in the Table of Contents.

The third section deals with organization of the items in the Table of Contents. By default, SharePoint orders the items in the Table of Contents to match the navigation. However, for large sites with many pages or many sub-sites, this may make it harder to find what you are looking for. Therefore, SharePoint provides a way to provide a custom ordering of sites and the pages within the sites.

If you select the custom sort option, you can sort the sites by Title, Creation Date, or Last Modified Date. You can also choose the direction of the sort as either ascending or descending. For example a descending sort on Creating Date will list the most recently created sites or pages near the top of the list making it easier to find what is new on the site.

After you have set all the properties, you can apply your changes and click OK to view your Table of Contents page.

That’s all for this week. C’ya next time.


When Plain Text Isn’t

One of the problems many beginner SharePoint content editors have is pasting text into SharePoint from other sources. The problem has to do with the unseen or hidden information embedded in the text that formats the text in these other products.

Take for example a typical passage of text in Microsoft Word as shown below:

If I were to simply copy this text from Microsoft Word into SharePoint, the result might at first look like a fairly good approximation of the original text as displayed in Word as shown in the following image.

However, when I look at the HTML of this text, I see that it is littered with embedded commands that would make it very difficult to edit by just looking at the visible portion of the text. The problem is that when I select text that is visible to me, I may not include all of the tags that wrapped around that text. Furthermore, if I were to try to change the style of the selected text, it may not appear to change if my selection included the original formatting tags that I want to replace, but are left in the code. The selection of the text may not even grab the embedded start and end tags, but only one or the other resulting in tags that are not property nested. The browser then struggles to interpret exactly what I want to do and may add additional but superfluous <div> tags to try to isolate the problem. While I could directly edit the HTML to fix these issues, I would not recommend this to the typical content editor unless I was very sure that they were familiar with HTML. In any case, the challenges of editing formatted text directly may be more than I typically want to handle.

One solution that I have been told to use in the past is to copy the text first to NotePad. NotePad does not support most of the special formatting features of Microsoft Word and therefore it strips out these embedded tags from the text. The following image shows the same text copied first to NotePad and then copied to SharePoint.

The text looks fairly clean of any special formatting. I might think that I can now easily go into this text and begin changing the formatting of specific portions of the text to match what I had in Microsoft Word. For the most part, I would be safe doing this. In fact, I am much better off than if I pasted the Microsoft Word text directly onto the SharePoint page. However, looking at the HTML of even this page, I can see that some special formatting still exists although it is not nearly as bad as the HTML pasted directly from the original Microsoft Word text.

Another option has been to try to remove the formatting from the text after pasting it on the page. To do this, I would first select all of the text that I just pasted and then open the Format Text ribbon as shown in the image to the right and select the icon that looks like the letter ‘A’ with an eraser to its lower right. The text that appears when I hover over this button says that it will clear all formatting from the selection leaving only plain text. While that sounds promising, in actual use, the results are less than I hoped for as the image below shows. Notice that the HTML, while starting to look fairly clean with only the actual text, still has a lot of formatting tags, specifically <div> and <span> tags.

Fortunately, in SharePoint 2010 there is another option, one that very few people find. Recognizing the problem with Copy and Paste, a method used by many people, Microsoft added a second paste option. When you are ready to paste your text in SharePoint, rather than just pressing the CTRL-V to paste the text that you have on the clipboard to the current cursor position, you can click on the lower half of the Paste button in the Format Text ribbon which happens to be the leftmost button on this ribbon. Clicking on the lower half of the button displays a submenu that includes the two options shown in the image to the right. The one that I am interested in is the option: Paste plaintext.

This time when I look at the resulting HTML, I see a much cleaner version of the text. The only special formatting left is the <BR> tags used to end paragraphs and create line breaks. The resulting text should be easy to maintain in SharePoint with the formatting tools in the Format Text ribbon.

In addition to the methods described here, there are many other text editing tools that allow you to either cut and paste text from your favorite editor or may even serve as an alternative text editor. I cannot attempt to evaluate them all here. Rather I will mention a few that I’ve heard of but leave it up to you to test whether they serve your needs. Two that come to mind are PureText for the PC which is a free download and Flycut for the Mac.

If you insist on using a browser other than IE (remembering that SharePoint was designed around integration with Microsoft products, not products from other companies), you might try one or more of the browser extensions for FireFox or Chrome that support copy and paste of just text. Just be aware that while some of these may work fine to copy text from one web page to another, they may not work fine with other applications such as Microsoft Word.

Finally, FireFox and Chrome allows you to paste just text by using the key combination CTRL+SHIFT+V. Similarly, the Macintosh uses the keys: Shift + OPTION + COMMAND + V.

If all of this seems like too much of a bother, remember that you can always create your text directly in SharePoint rather than starting from another text tool and then having to copy and paste that text into SharePoint. The SharePoint interface for entering text is very similar to Microsoft Word, or perhaps you use WordPad, and provides a good WYSIWYG interface for entering and formatting your text. Entering and formatting text directly within SharePoint practically guarantees that you will not have future issues editing the text.

That’s it for this week. C’ya next time.


Readability, that word refers to both the visual and the content of your text. To be readable, your text must first be visually easy to read. It may surprise you know that text on a screen is more difficult to read than the same text in print. In fact, printed text often is created using a serif style font such as Times Roman. The tiny crossbars on the letters of a serif font help the eye move horizontal across a line of text aiding in the ability to read more rapidly text in paragraphs and pages. To bring emphasis to titles and headings, a sans serif font such as Arial with its simpler straight lines and curves tend to make your eyes hesitate just a bit which helps titles and headings stand out.

Surprisingly, this should not be the way you format text for display on a screen. In fact, because it is more difficult to read text on a lighted screen, it is generally better to use an Arial style sans serif font to help make the letters clearer to read. Perhaps some of this is related to perceived character spacing since the straighter characters do not quite approach each other as much as do the serifs in a font such as Times Roman.

Pay attention to text size. Text that is too small or too large can make text more difficult to read. The problem here is multiplied by the different form factors that web pages, e-books, etc. have to deal with ranging from 24-inch desktop computer screens to 5-inch smartphone screens. Of course most electronic devices will allow the user to zoom in or zoom out of the text to effectively resize the text to their liking, but you may want to start with a font size that will make your text easy to read by the most number of users without manual adjustments.

Consistency in the use of fonts is also important. Once a font style is selected, it should be used for all content on all pages of a website. It can be quite annoying to deal with a different font style as one goes from one page to another (or even worse, one paragraph to another). This detracts from the sense of continuity between the different portions of the content. Sure you can use italics or special fonts for emphasis of small text segments. However, even putting an entire paragraph in a different font style can make it look like it does not belong.

Of course, all rules have exceptions. For example, you may place material quoted from another person or source in italics, or a different font style, or even a different color to purposefully bring emphasis to it. However, be careful of using type styles such as underlined text or certain colors of text in places where the user might misinterpret the text as representing a hyperlink.

Font colors should be carefully selected considering the background color to give the reader a high contrast. The greatest contrast is black text on white background or vice versa. However even here a white background is preferred for content read in normal lighting conditions and a black background is highly preferred for text read in the dark. In fact, some programs including some e-book readers have the ability to automatically flip the text and background colors based on the ambient light level. For example, my iPad’s iBook reader does that.

On the other hand, using a light blue text on a medium blue background may not provide enough contrast. A related problem I have seen is placing darker text on a black background such as a medium to dark blue or red on black. Also, some people perceive colored text on a colored background as being smaller than the equivalent black text on a white background. This is especially true of lighter text on a darker background.

Another consideration is the width of the text column. Generally web pages use two or more columns of text so that the reader can more easily move their eyes across the line of text and then quickly find their way down to the next line. The wider the text column, the more difficult this is.

Related to this is the size of the paragraphs. Longer paragraphs can feel exhausting to read compared to shorter paragraphs. Also, the use of shorter paragraphs forces the writer to condense their ideas into smaller more easily digested content nuggets.

Long web pages should be minimized. A user should not have to scroll down the equivalent of more than two or three screens to read the entire page. I’ve seen web pages that require the user to scroll and scroll and scroll to get to the bottom. Do you really think that users will ever find the content at the bottom of that page? Of course not. There is even good argument for a single article to be continued on another page after it begins to get too long. Don’t be afraid to break articles into multiple sub-topics that are then linked through multiple pages.

In addition to all the visual aspects of making your content readable, consider also the grade level of your writing and whether it is appropriate for your audience. Microsoft Word can analyze your text and report on its readability. To turn on this feature, open the File drop-down menu and select Options. In the dialog that appears, click on Proofing in the left column. Locate the section on the right side of the dialog: When correcting spelling and grammar in Word. Click the check box: Show Readability statistics. Now when you create text in Word, you can click the icon in the lower left status bar to the right of the word count. The resulting dialog box will give you readability statistics for your text including number of sentences in a paragraph and the average number of words in each sentence. At the bottom of the dialog is the Flesch-Kincaid Grade Level. Try to keep this number between 8 and 10. This document is an 8.7.

Finally, don’t try to eliminate all white space on a page. White space gives your eyes a chance to rest. A page completely filled with text and no white space between paragraphs or columns or around images is very hard to read.

C’ya next time.


Last time we talked about following a document. While the ability to follow a document is relatively new in SharePoint, alerts have been around at least since I started using SharePoint 2007. Alerts are more narrowly focused than the social tool: Following. By that I mean, alerts are available only to track changes to documents (or items in a list). You cannot create an alert on a user or tag. However, alerts provide some additional flexibility on what types of changes you want to track and when you want to hear about them. So let’s dive into alerts.

If I were to open any library or list, I can click on the Library (List) tab or the Document (Item) tab. In both ribbons, there is an icon with the name Alert Me in a group called Share & Track. Does Microsoft duplicate this feature on both ribbons for some reason? Actually, yes. The Alert Me icon in the Library or List ribbon is meant if you want to create an alert to changes to any document in the entire library or list. This feature is useful if you need to monitor whether others are adding, editing or removing documents or list items. On the other hand the Alert Me icon in the Document or Item tab can be used to monitor individual documents or items for changes. So the first thing I have to decide is whether I want to track changes to the overall library or list or to an individual document or item.

For the balance of this discussion, I will assume that I want to monitor changes to an individual document in a library. However, the technique that I will show here is essentially the same for monitoring changes to the entire library, an entire list, or just a single item in a list. I mention the differences at the end of this article.

If I want to create an alert, I need to select the document first by either clicking on a non-hyperlinked column within the document or preferably by clicking the check box in the first column of the document row.

Note, you may think that you can create an alert on multiple documents by selecting their individual checkboxes before continuing. Unfortunately, if you select more than one document, the Alert Me option in the Document ribbon becomes disabled. You can only create alerts individually on documents.

The image below shows the Alert me icon in the Share & Track group. I have already clicked on the lower half of the icon (where the down pointing triangle appears) to open the dropdown menu of options. In this case, I want to select the first (or default) option for this icon to set an alert on the currently selected document.

Next SharePoint opens a dialog which is rather long. Therefore, I will have to explain first the top half and then the bottom half. In the following image, you see the top half of the New Alert dialog. The first thing you need to do is to create an alert title. Because you can create many alerts on different documents in different libraries in different sites, you want to carefully name your alert so that when you manage your alerts (note the second option in the above dropdown) you can easily identify the alert that you may want to change or delete.

A side note on managing your alerts. You can only manage alerts within a single site at a time. You cannot see all of your alerts within a site collection or a SharePoint farm, at least not with the built-in tools. There are some 3rd party scripts that will help you see and delete alerts across all your sites. I may discuss this in a future blog.

Although I’m not going to go into detail here about naming conventions (that is almost like talking about religion or politics), you may want to consider the following factors in defining your alert name:

  • The name of the site/library
  • The name of the document
  • The type of change you want to have the alert monitor.
  • The frequency of the alert reporting

I will show you the latter two factors when we get to the second half of the dialog in just a moment.

The second thing you may need to do is define to whom you want to send the alert. By default, most users want to receive the alert themselves. In fact, unless you have owner rights to a site (as I do), you can only create alerts that you receive and you will not be able to enter users for this property. On the other hand, site owners can create a list of users separated by semi-colons to specify who should receive an alert.

In addition, you may or may not have the ability to send the alerts by E-mail or text message depending on how your SharePoint administrator has set up your system. I’ll assume that e-mail notification will be on for most users and create my alert that way.

Moving to the second half of the dialog, the next property of the alert I can set is to define which types of changes I want to see in my alert. Read these options carefully. Only the first option, Anything Changes, will report changes that I myself made to the document along with changes from others. I may not want to see my changes since I already should remember them. Therefore, the other three options become more interesting. The second option shows me changes that anyone but me made to any document. Again, I may not care so much about changes made to other people’s documents, but only documents that I added to the library. In that case, I might select the third option. Perhaps even that is too much information. Perhaps I want to know when someone else comes in after I have made changes to a document, whether I originally created that document or not, and may have made changes on top of my changes. Then I would select the last option in this group.

The last option I can set for a document alert is when I want the alert sent. I could ask to see the alert immediately (or at least within a few seconds). Unless knowing about the change is critical, this may be more annoying that it is worth. Perhaps I would prefer a daily summary of all changes made to the document. Sure that may mean that I may not be made aware of a change for up to 24 hours after a change was made, but that may be enough. Note that if I select this option, I will have to select what time of day I want to receive that alert. In the figure above, I selected to receive the alert at 1:00 PM.

Finally, I can choose to receive a weekly summary for the alert. In that case, I must define not only the time that I want the alert sent, but also the day of the week I want. For example, I might want to see my weekly alerts first thing Monday morning.

When I click OK at the bottom of the dialog, SharePoint saves my alert definition and begins monitoring for the changes I asked for. If any changes occur to the document in the current reporting period, I will receive an e-mail detailing the changes. If no changes occur, no e-mail is sent.

There is one significant difference when creating an alert on an entire library or list, I can specify whether I only want to see:

  • when new documents are added to the library,
  • when existing documents are modified in the library,
  • when existing documents are deleted from the library,
  • or all of the above.

Note, it is not possible with a single library alert to see only additions and deletions to the library. Either I have to deal with receiving a single alert with all changes to the library or I can create two alerts, one for additions and one for deletions.

So as promised, why would I use an alert over following or vice versa? First, I like getting email alerts about changes and not having to go to my Newsfeed page. Also I like the fact that I can customize the type of change to the document or the library that I’m interested in and not have to wade through changes that do not interest me. On the other hand, alerts do not let me following people or tags to let me know what else individuals are doing or where other similar content may be. I can also follow documents and libraries without having to implement e-mail or SMS services which alerts require.

So I hope now you know how to decide whether you want to follow objects in SharePoint or to receive alerts. Each has their place if you use them wisely.

C’ya next time.

Default the Month

It has been awhile since I posted anything new.  Ok, it has been nearly a half year.  Perhaps as my new year’s resolution, I will try to get back on a regular basis here.  It may not be twice a week like before, but I’ll try to do something weekly.

I’ll open the new year with a short tip. Suppose I wanted to create a list which had Month as one of the fields and I wanted to default that field to the current month. Obviously I cannot simple enter the name of the month as the default value, but I notice that the Default property has the option of defining a calculated value. So I begin by creating a new field named Month2 and declare it to have the type: Choice. Why Choice? To eliminate the chance of misspelling the month name should the user need to enter a month name other than the current default month.

After choosing the data type for the field, the property settings for the column appear on the second half of the screen as shown in the next figure. Note that I entered all of the month names in the list box containing possible values. I also chose to use a drop-down box with no fill-in values. After all, the month name must be one of the values in the system. However, the important property is the default property which appears close to the bottom of the list. Notice that I chose not to allow fill-in values.

The calculation of the default value looks a lot like an Excel expression. It uses the special variable: TODAY which returns the current day’s date. Next it uses the TEXT() function which has two parameters. The first parameter is the date for which I want the month returned. In this case, I can use the special variable TODAY. The second parameter identifies how to format the date. In this case, the string “MMMM” will return the full name of the month. (Note: “MMM” returns the 3 character month abbreviation, “MM” returns the month number with a leading zero such as ’01’, ’02’, etc.)

After completing all the field properties and clicking the OK button, I can open the list and add a new record. As you can see in the figure below, the form opens with a default value in Month2 (screen images were captured back in July 2014). Note that the default value, although calculated, cannot depend on the values from another column since at the time the form is instantiated, none of the other fields for the current record have been entered.

The value on the form is a true default as you can see when you open the dropdown for Month2 which shows the month of July as being selected.

Can you add a dropdown for the day of the week as well? Sure, just change the formula to:

= TEXT(Today, “DDDD”)

You might even want to a field to default to the current year, last year, or perhaps next year.  Hope this little tip on how to work with calculated defaults for date fields helps.

C’ya next time.

Governance For All

I was thinking about SharePoint governance today and its effect on the success or failure of SharePoint. Fundamentally, SharePoint governance is a document that forms an agreement between the people who support SharePoint and rest of the organization. It then dawned on me that I could substitute SharePoint for any other system. However governance is an umbrella covering many things such as policies, rules, roles, and responsibilities. Within that umbrella of governance, I would like to think of these four areas as represented by the four legs of a chair, the chair being the system. Failure of any one leg may not make the chair crash, but it will make it less stable. Failure of more than one leg can cause the chair to collapse.

The same is true of SharePoint governance. Without adequate policies, rules, roles, and responsibilities, your SharePoint implementation may be on the verge of collapse. The hidden problem at many organizations is that even if you initially create a sound governance policy, if it is not followed and enforced, it may be as bad as not having a governance policy at all. What may begin innocently enough as a minor exception to the rules or policies here and there, can quickly slide down the slippery slope to total chaos. Stay with me a minute.

While governance may seem to be filled with a lot of rigid policies and rules, governance, whether for SharePoint or for any other major system in your organization, must be flexible. It must be almost an organic thing. By that I mean that it must be adaptable to the changing needs of the organization. A change in needs might be something major such as the addition of outward facing web sites to your existing farm of collaboration sites, or it may be something as simple as a font change used for the body of content. The thing to remember is that all change sets a precedence. The question you should ask is whether that is a good precedence that you want to set or a bad one?

Once policies and rules are established and made part of the governance, then changes or exceptions to these policies need to be very carefully vetted and then added to the governance so it does not open the door to other changes that may be less desirable. For example, if the initial governance called for Arial fonts, exceptions might be made for other similar fonts such as Calibri. However, as soon as you begin allowing Times Roman or Impact, you are on the path to allowing Broadway, Playbill, and even Comic Sans Serif. But governance can stop that that by specifying that any font from a limited list of fonts can be used, but only one font can be used per page or per subsite. The same can be said for colors, page layouts (themes), and other visual effects. In addition, the governance should define a method to request changes to policies and rules. Perhaps those requests get funneled through a single person, but more likely they should go to a committee that decides on any governance changes.

However, even if you have all the policies, rules, roles and responsibilities well defined and you have a committee to review and approve or reject any changes to the governance, if you do not have upper management’s full support of the governance, your efforts are in vain. Like a dragon without fiery breath or at least large sharp teeth, users will soon realize that they can get away with anything with no more consequences than your pitiful cry to never do that again. You must have management’s support to enforce the governance.

The problem is that maybe management just came back from a conference, or perhaps it was from a free seminar provided by an alternative vendor who provided a lunch ‘n learn at the local steak restaurant. While the product demoed does basically the same thing as your current product, marketing demos are very good (or they should be) at highlighting the best features of the product making it look like the new and most desirable product on the market. Rarely does the demo go into how much time or skill was needed to set up the demo. Of course demos are meant to look flawless and so simply that your dog could do it with one paw tied behind its back. It is your job to be able to tell the difference between a well-crafted demo and a system that is truly easy to use before your organization starts spending money on something it really does not need.

But here is another big ugly secret. No system can be successful without governance and top management support. Individuals resist change. They will refuse to learn how to use a system. They will claim a system is too hard to learn or to use. They will blame their own mistakes on the system or on the restrictive governance policies or the lack of training that fits their exact circumstance. Management must lead from the top down with strong reasons why the policies and rules will serve the organization as well as the users better. Governance gives them a way to make that happen by formalizing the policies, rules, roles, and responsibilities of any major undertaking. Governance is leadership by getting out in front of everyone and saying, ‘Follow me and be successful.’

Well I’m off to another SQL Saturday this weekend again, this time in South Florida. How does this fit into today’s mini topic? At SQL Saturday there will be hundreds of individuals who as DBAs or developers use SQL Server and have policies and rules they follow when using SQL Server. They have specific roles defining what they can and what they cannot do. They have certain responsibilities to perform specific tasks using SQL Server. What makes SQL Server work or not work within their organizations is largely dependent on how well they embrace the governance around creating, using and maintaining databases and the processes that access those databases within their organizations.

You see it is not just about SharePoint or SQL Server or any other specific product. The need for governance applies across all products and activities in the organization as does the need for management support of that activity. No organization would arbitrarily switch from using SQL Server to Hadoop to Informix to ingres to Oracle to Postgres to Access or any other database system every couple of years. Rather, they would choose a product that best fits their needs and wring out all the value they can from it by insuring that their staff is trained and supported in its use. Don’t expect a new product to somehow produce magical results. If anyone is responsible for magically results, it is an organization’s people. What does your governance say about how you use technology and your staff?

C’ya next time.

OOPS! I Didn’t Mean To Delete That

Using the Recycle Bin

If you have content management rights to your SharePoint site, you may have one time or another accidentally deleted the wrong document, list item, image, page, or even worse, the entire site. The first thing to remember when you do this is not to panic. The second thing to remember is that you need to act sooner rather than later to restore the item you deleted.

Deleting the wrong item out of a list or library is a relatively simply thing to fix. In the following image, suppose I accidentally deleted the Word Document: How to Approve a Page.

When a person deletes an item from a library or list, SharePoint puts the deleted item in the Recycle Bin. That person can open the Recycle Bin by either selecting Recycle Bin which is typically found at the bottom of the bottom of the Quick Access menu unless custom branding has moved it somewhere else.

They can also get to the recycle bin by opening the Site Actions button and clicking on View All Site Contents (or clicking on the All Site Content link in the above image) and scrolling to the bottom of the page. This view of the Recycle Bin tells you that you can restore items that you have deleted from this site.

This is an important distinction because you can only restore items that you have deleted. You cannot restore items that someone else has deleted, well most users cannot. But we will get to that later.

When you open the Recycle Bin using any of the above methods, you will see a list of items that you have deleted. You can select an item to restore by clicking on the empty checkbox on the far left of any item and then clicking the Restore Selection option. You can even select multiple items from the Recycle Bin by clicking on each of their checkboxes and restore all of them with a single click.

The Restore Selection option restores the selected item to its original library location. If you had additional metadata associated with that item, SharePoint will also attempt to recover that metadata. Be careful however, not to click the Delete Selection. If you select one or more items from the list and then click the link Delete Selection, you will delete the item from the Recycle Bin. At that point, the only way to recover the item is either by requesting a site restore from a backup or by bribing your Site Collection Administrator to restore it from the Site Collection Recycle Bin. More about that later.

This restore technique works for any item in a library and includes documents, images, pages, and even items in a list such as individual announcements from an announcement list.

You should note however that items only remain in the Recycle Bin for a maximum of 30 days. Well, it is 30 days for us. However, your SharePoint administrator can change that setting. After that point, the Recycle Bin automatically flushes the old item from the bin and it is no longer possible to restore it. The Recycle Bin may also start to delete older items if it starts to run out of available space.

Recovering Items Deleted by Others

So what happens when another user accidentally deletes something from a library but they are no longer in your department or company? There is the ability for the Site Collection administrators to restore items from the full site recycle bin. First you must find your Site Collection administrators and then request that they retrieve the item(s) from the recycle bin. You must either supply the name of the item(s) to be recovered or ask them to send you a full list of all the items in the recycle bin from which you can choose which items to recover. Note that this process can take extra time and the 30 (or whatever your number is) day restriction to recover deleted items still applies. So do not delay.

Deleting a Site

How do you accidentally delete a site? First of all, not everyone can. This is a limited feature capability that only site owners and other roles that you have given Delete Site permission to. That being said, it involves first going to the site to be deleted and then selecting Site Settings from the Site Actions dropdown. In the Site Settings page, look for the option Delete this site in the Site Actions group and click on it.

In an attempt to protect you and the site, SharePoint asks whether you really want to permanently delete the Web site and its contents as shown in the following image. You could still abort the process at this point by clicking the Cancel button, but if you click OK, SharePoint will delete the site.

In earlier versions of SharePoint such as SharePoint 2007 or WSS 3.0, deleting a site was truly permanent and the only way to recover from such an error was to restore your site or possibly site collection from a backup. However, beginning with SharePoint 2010, deleted sites are also stored in the Site Collection Recycle Bin. Unfortunately, you need to be a Site Collection administrator to access the Site Collection Recycle Bin to find the deleted Site. (Think about it. If the deleted site was only in the Site Recycle Bin, then deleting the site would also delete the Recycle Bin. Therefore, Microsoft decided to place deleted sites in their parent Site Collection Recycle Bin. That also means that if you delete the site collection, there is no safety net other than restoring the site collection from a backup.)

To recover a site if you are a site collection owner, open the Site Collection Recycle Bin which is accessed from a brief paragraph at the top of the regular Recycle Bin in any site in the same site collection.

Using the Select a View menu on the left side of the screen, the site collection administrator must select the option: Deleted from end user Recycle Bin. This gives us a clue that any file deleted from an individual’s recycle bin (document, image, page, etc.) can be recovered the same way as recovering the site by going to this option. This is apparently what the previous warning message means by saying that it is permanently deleting the site. It is by-passing the individual’s recycle bin and going directly to the site collection recycle bin.

Note: the first and default option under Select a View, End User Recycle Bin Items, lets the Site Collection Administrator recover any deleted file from any user in any site within the site collection.

To restore the site, the site collection administrator simply selects the site (or other file) to be restored by placing a check in the checkbox to the left of the appropriate site and then clicking Restore Selection. Clicking Delete Selection here will truly delete the site permanently that only a restore from backup can undo.

If you are restoring a site, SharePoint also prompts you to confirm that you want to restore the named site. You have the option to continue by clicking the OK button or to cancel the restore by clicking the Cancel button.

You can see that the site has been successfully restored by clicking on View All Site Content in the Site Actions menu and scrolling down to the Sites and Workspaces section. The restored site should be back in the list of available sites. You can navigate to the site by clicking on its name

I hope this article gives you some idea of how to recover a deleted object in SharePoint 2010 and better.

C’ya next time.

Lists and Libraries on Public Web Sites – Part 2


Last time we looked at the problem of referencing lists and libraries directly on a public facing web site after adding a link to the Quick Access menu when creating the list or library. However, that is not the only way you can get into trouble.

On a public facing site, it is possible to display the contents of a list or library by displaying a view of the library or list. To do this, all you need to do is open an existing page or create a new page, select a web part zone where you want to display the list or library and click Add a Web Part.

The Insert ribbon that appears includes a panel beneath the ribbon that shows the web parts by category. You can add any of these web parts to the zone.

In the first column of this panel (named Categories) select the Lists and Libraries category. This displays a list in the column Web Parts to the immediate right that shows all lists and libraries in the current site. This section supports two columns of eight items each. If you have more than sixteen lists and/or libraries in the site, navigation arrows at the bottom of this section (greyed out in the above image0 allow you to scroll right and left to view additional groups of up to 8 lists or libraries with each click. Let’s assume that I want to display the Documents library. I need only select it so it is highlighted and then click the Add button in the lower right corner. As you can see, this adds a view of the library to the page.

Once the page has been published (assuming you have publishing turned on for your public facing sites), an anonymous user might open the page, see a Microsoft Word document, as shown above, and attempt to click on it. As an anonymous user, they do not have rights to edit a document. If the library is set up to download the document to the client, SharePoint displays a security dialog such as the one in the next image prompting the user to log in before it allows the document to be downloaded.

But anonymous users do not have user names and passwords. Therefore, all they can do is cancel the action. One solution might be to also upload a PDF version of the document. This is relatively easy since all Microsoft Office applications can output a PDF version of their documents.

Even with a PDF, SharePoint needs to download that PDF to the client. But since a PDF is not considered to be editable, there is no security warning. Instead, it considers a PDF to be an executable file. Therefore, the user gets a dialog warning them that some files could harm their computer when they are executed.

Of course, if you go this route, you may want to clean up the library display to use a view that filters on only the PDF files in the library. However, even if you do that, there is still an issue with the dropdown menu associated with the item.

Clicking on the menu dropdown as an anonymous user also opens a Windows Security dialog:

So what can you do to display items in a document library that people can open? One method that I have found effective is to use the Content Query Web Part to display the items from a library. Using this web part, you can filter (such as on PDF files) and sort on one or more columns to create a list of links to your documents. But even this method could still prompt you with the message that you are downloading a potentially harmful file to your local computer.

One solution we implement to solve this problem was to install Microsoft Office Web Apps on our SharePoint servers. Then we would open the library, open the Library ribbon, and click on Library Settings. On the Library Settings page under the General Settings group, click on Advanced Settings.

Then in the Library Settings, we turned on Use the Server Default which is to open in the browser (we could also use Open in the Browser). This will force Office Web Apps to try to open the document, even Microsoft Word documents can be directly opened this way without prompting the user for a username and password. PDF files will also open in the browser without a warning about the file potentially harming your computer.

To display a list, we found a slightly different solution. The problem with lists is both one of clicking on the title (default) column of the displayed list and clicking on the dropdown menu associated with the title. However, the list problem can be solved most elegantly by simply changing the columns displayed in the list view. By default, many people select the Title column (renamed in the image below as OpenLabID) to appear in the list. Note that in parenthesis that this column is linked to the item with an edit menu.


Simply replace this column with another version of the column named Title (or OpenLabID in this example) that does not link to the edit menu.

Now when you display the list to users who do not have edit rights, the viewers can see the data without having to worry about whether they have rights or not.

Hope this gets you through a few problems.


C’ya next time.

Never Display Lists or Libraries Directly on Public Web Sites

Most people think of SharePoint as a collaboration tool. Relatively few of these people think of using SharePoint to create their corporate web presence. Like all tools, there are pros and cons to this decision and I’m not going to debate those here. I’m just going to assume that you your organization has made the decision to create their public facing web site using SharePoint.

In fact, our organization made that decision seven years ago. Because of the size of our organization, content management was decentralized giving each department control over their own site content. Overall that decision has been good. However, there have been several issues that have come up over the years. Their solutions may also be of interest to others. Therefore, I will occasionally explore one of them as a blog topic just in case they might help others.

A common problem that occurred on our public sites when we were using SharePoint 2007 and SharePoint 2010 stemmed from anonymous users attempting to click on links in the navigation that attempted to display a list. While it is possible to display a view of a list or on a public site page (see next week’s article), that view cannot contain a link back to the properties of the list items. The problem occurs because anonymous users do not have edit rights to the contents of a public site. It does not matter whether are attempting to open a list or library directly or attempting to access the properties of an item in a list, SharePoint displays a prompt to log into the site. Since an anonymous user does not have a login, this situation is frustrating.

Lets first deal with the first problem, the one where you attempt to directly open a list or library. In this case, the content editor probably created a site but did not select the option to NOT include it in the navigation. When creating the list, the content editor simply supplied the name of the list and clicked the Create button. This resulted in SharePoint making some assumptions. The assumption of concern is the automatic inclusion of the new list in the Quick Links navigation. For a collaboration site or even an intranet site, this assumption may be exactly the choice you would want so that users could easily navigate to the list and interact with it. When these users click on the list link in Quick Links, SharePoint opens the default view of the list and allows the user to view and edit the contents of the list (assuming they have rights). However, anonymous users will never have edit rights to the lists or libraries in a public SharePoint site. But because SharePoint does not know who the anonymous user is who is attempting to open a list directly it asks the user to log in. As a public facing site, this action can be frustrating to these users because they have no way to log in.

Fortunately, there is an easy fix for this problem. In fact, the content editor only needs to click on More Options after supplying a list name instead of simply clicking on Create.

By going to More Options, the content creator has the ability to not display the list in the navigation (the Quick Launch) by selecting No in the Navigation section.

If they forget to do this, they can recover by selecting Site Settings in the Site Actions dropdown.

Then they select Navigation in the Look and Feel group of the Site Settings page.

Next, they can select the entry for Lists in the Current Navigation (which is the Quick Launch area) and click on Delete in the header options in the Navigation Editing and Sorting section.

This removes the heading entry for the list since there could be multiple lists. However, they must also go back and remove the list entry as well because an anonymous user cannot open the list directly. If they only remove the actual list, the heading entry would still remain.

After removing these entries from the Current Navigation area, the content creator must click on the OK button at the top or the button of the page or their changes will not be implemented.

Next time I will look at the similar, but related problem that occurs when inserting a view of the list on the page rather than just providing a link to the list to show how even this can cause problems with anonymous users. Of course I will explain how you can solve that issue as well.

C’ya next time.

Understanding SharePoint Metadata – Flattening The Hierarchy – Part 2

Last week I tried to explain the concept of metadata in terms of things you already know and use in Windows directories. So when it comes to storing documents in libraries in SharePoint did you expect SharePoint to be any different? The simple answer is that metadata works pretty much the same way in SharePoint as it does in a Windows directory. However, there are some additional reasons why you might want to consider minimizing or even eliminating your folders when creating SharePoint libraries.

First there is the concern that when multiple people are sharing a common library, the complexity of the tree structure creating by having folders within folders within folders can often result in the user getting lost when trying to find or save a file. The danger here is not just that a user may get lost in the forest of folders when trying to find a file and waste valuable time navigating up and down various branches to find the file they need, as bad as that may be, but the very real danger that they may save files to the wrong branch. When a user is saving a file in a library with a very complex folder structure, they may not immediately find the folder they want and assume that it does not exist. Then then create a new folder with the same name as a folder on a different branch of the library to save the file. Potentially, this can result in different versions of the same file (or files that should be related within a single folder) to be found in different branches of the library structure. If the file is actually saved in more than one location because of this error, subsequent updates to either file could occur independently from each other resulting in divergent copies of the document. When someone realizes the problem and attempts to bring the two copies of the file back together again, the process of manually merging the differences between the files can be a challenge.

The second reason however has a greater chance of causing problems. SharePoint only supports URLs with a length of about 260 characters (some say 255 or even 256, but let’s not quibble over a couple of characters.) This length typically does not include the name of the domain/server. However, there are also limits on the length of any folder name or filename of 128 characters. But hidden behind this limitation is the fact that some characters do not get passed as you and I may view them on the screen as single characters. These are the special characters, the non-alphabetic and non-numeric characters that must be passed as encoded strings so that the web engine does not incorrectly interpret them. Each of these special characters must be converted to three characters that represent the ASCII value of the character as a hexadecimal number. The following table shows some of the more common characters that must be converted to their three character hex equivalents before being passed as a URL string of which the total length cannot exceed 260 characters.


Hex Equivalent

Ampersand (&) %26
Equal (=) %3D
Period (.) %2E
Question Mark (?) %3F
Slash (/) %2F
Space ( ) %20


Thus, it is possible to have a path which may look like it has less than 260 characters when you count the characters in the path as you read it, but the length could exceed 260 characters after it has been encoded so it can be passed as a URL.

Note that this limitation does not apply to any query string appended to the end of the path to the actual file.

Perhaps even of more concern is when the site gets translated into some languages which can convert a single character consuming 1 byte as we see it into a string of up to 9 bytes.

Where do we most often see this? If a library has a complex folder structure and its users always navigate down through the structure one level at a time to the specific file they want, they many never know that they have a problem just because of the incremental way in which they are approaching the file. However if they attempt to capture the URL of a file buried deep within the structure, the resulting URL may look correct when they past it into a hyperlink or into an email message for someone else to directly view the file without navigating the folder hierarchy. However, when the person who receives the link attempts to click on it, which pastes the encoded link into the search box of their browser, the resulting encoded string may be truncated because of the extra characters added by encoding the link. This truncated string no longer points to a valid file in the library and the user will receive an error indicating that the file does not exist or that the URL is not valid.

So how do you trim your folder hierarchy and use metadata instead?

The simplest method is to first map out your hierarchy as shown in the following diagram showing only the names of the folders (symbolic folder names have been used here to keep the example as small as possible.)

Referring to the above figure that represents our folder structure within a library, notice that I color coded each level under the library’s root level. The folders immediate under the root are colored Yellow. The folders that are found in the Yellow folder level. These are colored Blue. The Blue level also has folder which are colored Green. Now converting this diagram to metadata, I can create a new library with no folders, just three new metadata columns. Each metadata column would represent one of the color bands. Within that metadata column, possible values will be the names of the folders from that level. For example, within the Yellow column, the possible values are: Folder A, Folder B, and Folder C. Next I create a Blue column with possible values of: Folder A1, Folder A2, Folder A3, Folder A4, Folder A5, and Folder A6. Finally I create a Green Column with values: Folder A1a, Folder A1b, Folder A1c.

Now when I add a file to this new library with no folders, I choose from the possible values in each of these three metadata columns to ‘place’ the file in the correct hierarchy level. If a file was in the original library’s root level, all three of these metadata columns would be blank (empty). For any file that was in the folder: Folder A, I would select the value ‘Folder A’ in the Yellow column and leave the Blue and Green columns empty. Similarly a file that was deep in the folder Folder A1b would be placed in the root of the new library with and I would select the value ‘Folder A’ for the Yellow column, ‘Folder A1’ for the Blue column and ‘Folder A1b’ for the Green column.

The net result is that I now have a flat structure for my library that makes it easy to find files because there are no folders and all files are visible in the default view. I can then use the library’s column headers to sort the files or even to filter files. For example, If I filter the Yellow column on the value, ‘Folder A’, the Blue column on the value ‘Folder A1’, and the Green column on, ‘Folder A1c’ I can quickly see only those files that would have appeared in that folder three levels down in the original structure

But more importantly, with the use of other metadata such as the Created By column which appears by default in document libraries, I can filter on all the files created by a specific person no matter which folder they were in previously to quickly find all of that person’s documents without having to navigate up and down through the previous folder hierarchy. I can also apply multiple filters such as files created by a specific person that were in Folder B or any of its subfolders.

While not shown in this diagram, it is possible to even have files that may have existed in Folder C2c without there ever having been a folder at level Folder C2. This would be very easy to represent in the metadata by providing a value for the Yellow column and the Green column while leaving the Blue column empty.

The challenge is mapping out the folder structure as shown in the earlier diagram making sure that you capture each of the current folders in the library and assign them to an appropriate level.

While this technique may appear at first to be very different from the folder within a folder approach used previously, it really is not so different at all and you should be able to get used to it very quickly. Now that the hierarchy has been flattened, you should never run into a problem right clicking on the name of a file in the library to get its shortcut.

You can then past that shortcut into a hyperlink or simply add it in the body of an email when you want someone else to open the file rather than attaching the entire file to the email. This will save space in your Outlook mailbox as well as reduce some of the strain on your Exchange server.

Hope this helps you understand how metadata can help you slay the nested folder dragon.

C’ya next time.