private static AttachmentPath.Folder GetFolder(HttpContext context, string[] segments) { StringBuilder path = new StringBuilder(); for (int i = 0; i < segments.Length; i++) { path.Append("\\"); path.Append(segments[i]); } return(AttachmentPath.GetFolderByName(path.ToString())); }