andrew4582

IsUNCPath

Nov 5th, 2011
216
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.26 KB | None | 0 0
  1. public static bool IsUNCPath(string path)
  2. {
  3.     if (path.StartsWith(@"\\"))
  4.     {
  5.         int num = path.Substring(2).IndexOf('\\') + 2;
  6.         if ((num > 2) && (num < path.Length))
  7.         {
  8.             return true;
  9.         }
  10.     }
  11.     return false;
  12. }
Advertisement
Add Comment
Please, Sign In to add comment