2011-03-15 37 views

回答

5

看看Uri班。

Uri uri = new Uri(@"\\Myserver\myshare\myfile.txt"); 
uri.Host == "Myserver" 
0

这是正则表达式:\\\\.*?\\