UNC Path Naming for files stored on SharePoint

If you didn’t already know, you can access any file stored in SharePoint (2007 or 2010) as though it was a folder on your system. The secret is to make it a network drive. You can do this a couple of ways. The easiest way is to open the library in Explorer. In SharePoint 2010, you’ll find this option in the list ribbon, on the library tab. Depending on the width of your screen, this may only appear as an icon.

image

Once you click on it, you’ll see your files in a regular Explorer Window. Depending on your Explorer settings, you may also see a folder named forms. Do not touch that folder, and do not attempt to add a new folder named forms…. you will break your library. That folder contains the files necessary to properly render the library in a browser. Just pretend that it isn’t there.

Once you do this, your system will “remember” this library and you will be able to to navigate directly to it through the Network node of your Explorer window.

image

You can also add this link directly, by right clicking on your computer in the explorer view, selecting Add Network Location, and entering the URL of your library (or server) there.

image

This is all possible due to the magic of WebDAV (Web Distributed Authoring and Versioning). It’s a protocol for transferring binary files over http and is what is behind the concept of web folders. It’s an interesting acronym because the none of the implementations of the protocol that I’ve ever seen (it’s been around for about 12 years now) have anything at all to do with versioning,but I digress.

For any of this to work,the WebClient service must be running on the client machine, and if you’re using a server operating system, the Desktop Experience must be installed.

This works great for most cases. If you’re opening the files in Word, Excel etc, those applications understand that they’re opening content in SharePoint and they’ll happily write directly back to it……in most cases. The problem is that what is actually happening is that the file is being brought down locally, and synchronized back to the server, or written back directly by the application.

We recently came across a case where we were using an Excel spreadsheet that was stored in SharePoint as a data source in an SSIS (SQL Server Integration Services) process. Everything worked just fine, but the package was not picking up any changes. As it turns out, when we told SSIS the source path of the Excel file, we used the WebDAV address, which was http://server/site/library/filename.xlsx. What then happened was that SSIS pulled down a copy of the file to a temp folder, and then used that file from then on. Not so good.

The fix for this was to use a UNC path (the standard machinenamesharedfolder style). What is the UNC path for a WebDAV folder? It’s not well advertised, but it’s

\ServerURLDavWWWRootSite1NameSite2NameLibraryNameFolderName

Server URL can be a FQDN or a machine name, depending on your configuration, and the site structure begins after DavWWWRoot. The DavWWWRoot is a constant that tells Explorer that it is dealing with WebDav, and must always be present.

It’s probably a good idea to use the UNC path whenever you need to programmatically access files stored on SharePoint.

Advertisements

Storing Data In The Cloud

Last week, my colleague Ed Senez posted a very good article about cloud computing, and it’s benefits.Our company has been making moves toward the cloud for a couple of years now, with both Microsoft’s BPOS offering, and our own SharePoint Extranet Accelerator. While companies struggle with the benefits and risks of moving pieces of their business to the cloud, I can see a huge role for the cloud in the consumer space, primarily because it is so cost effective. I have been moving a lot of my personal data to the cloud for the past little while, and I thought that I would share my current observations.

Photos and Videos

Almost any Facebook user is familiar with posting pictures. The social functionality is great – tagging people lets all their friends know that they are in a new picture (maybe not so great if you don’t like the picture, but I digress….). YouTube is of course great for uploading and sharing videos, but both of these services have one drawback – they convert the files on upload resulting in a loss of fidelity. If you care about the quality of your source content, you can’t rely on these services for backup.

This fact led me a few months back to Flickr. At first look, Flickr had a lot of limitations too – a maximum file size,and a maximum upload rate per month,which initially caused me to dismiss it. What I found out was that with the subscriber version there are no limits at all – you can upload to your hearts content, and it will store the images in their true source format. I have been doing just that when I could for the past few weeks, and currently have over 2000 pictures in my photostream. Just 8000 or so to go.

Flickr also allows you to share your pictures publicly, with family and friends, or just keep them private. However, Flickr doesn’t have Facebook’s ubiquity, so I use it for purely public pictures only, and continue to rely on Facebook primarily for sharing and people tagging. Flickr does allow for videos as well, but it does have some size limits, so I will be relying on YouTube for sharing my videos, along with a separate backup strategy (see below) as I get my videos organized.

So how much does this cost? For $25 per year, I know that all of my personal pictures are backed up. Pictures are quite literally irreplaceable. Documents can be recreated, but you’ll never have a chance to capture those precise moments again. The fact that I can use the services to share picture (in full source quality) is really just a bonus.

Simple Storage with SkyDrive

Did you know that you have 25 GB of storage in the cloud that you can use free of charge? If you have a Windows Live ID (also free..) then you do. It’s called Sky Drive, and it’s extremely handy. Simply upload the files you wish to private, shared, or public folders and they’re safely secured away and accessible from any machine with a web browser. Because SkyDrive also uses WebDAV, you can map your SkyDrive folders directly to folders on your computer.

When you are navigating through your SkyDrive, you also have access to the recently released Office Web Applications. These are light, browser only versions of Microsoft Word, Excel, PowerPoint, and One Note, and they’re completely free of charge. You can create a new document using these apps, or edit anything that you upload. These apps are very handy for occasional use, for viewing purposes, or just for accessing an Office document that may have been sent to you when you don’t have the Office applications readily available.

Sky drive should pretty much eliminate the need for FTP servers, certainly for personal use. Given the cost of the service ($0.00), I really don’t see why someone wouldn’t want to take advantage of it.

Backup

I think that everyone that has used a computer for any amount of time has at some point lost data. Afterwards, there is a mad rush to back up the systems, and then make sure that there is a system in place to back everything up. Corporations typically have solid backup strategies in place (that aren’t tested frequently enough, in my opinion), but personal users are often too busy to ensure that their data is backed up in a timely fashion. There are a ton of consumer backup product out there, but they all often have one fatal flaw. They require the user to actually do something to make it work.

This is where the cloud can be of great help. If we can assume that the machine will typically have a connection to the internet, then for all intents and purposes, our backup destination is always available. All that is needed is a good service to make this painless and automatic for the end user. There are a number of such providers out there, and I’m going to briefly discuss the one that I’ve settled on – Carbonite.

With Carbonite, you download a small application that runs in the background, and is constantly ensuring that your files are being backed up. For most users it is as simple as a next – next install, which will backup all standard data folders. If you want to back up a non standard folder, just right click on it and choose to add it to the backup. You can always see what the backup status is from the console, but carbonite also (optionally) places a small indicator over the icon for each file that you have to let you know its backup status. The backed up files are also browser accessible from any internet connected PC, allowing you to access your files in a pinch, and one of the nicest features is that it not only keeps a mirror image of your system off site, it maintains file versioning, so when you make a change to a file and later decide that it wasn’t such a good idea, you can retrieve a previous version.

Given most end users’ bandwidth constraints, the initial backup can take a little while. Mine took two weeks, but that’s me. After initial backup, it all goes very rapidly. So what’s the cost of all of this storage? You can back up as much as you want from a single machine for $55 US per year. To me, that’s a no-brainer.

 

I spend about 5-10% of my time inside my company firewall. Tools to help with remote connectivity are crucial, and I really see a place for cloud based services to provide a lot of these tools. They’re safe, they’re easy, they’re useful, and they’re highly cost effective. In storage alone, I now back up all of my important personal data (redundantly I might add) and enhance my convenience in accessing it. All for less than $100/year.

I’m sold.