Here's one that caught Alex out the other day, although he's still not sure why it started happening. It's something I'd not run into, nor thought about much, but you need to be careful of case sensitivity when using Server.MapPath, as the file/path you pass in is returned as is and not with the casing of the actual file/path. For example, if I have a website at C:\Web\foo, with a subfolder of iMaGes and do Server.MapPath("IMAGES"), what I get back is C:\Web\Foo\IMAGES, not C:\Web\foo\iMaGes. In many ways this makes sense as it returns what you ask for (Windows paths aren't case sensitive, but on other platforms they are), but in some ways it doesn't make sense (why not return the actual path asked for).
Why is this a problem? Well, if you split the last part of the path out for a string comparison without converting the case, your comparison might fail.