写个c#函数把196.168.16.23 改成192.168.16.*????
写个c#函数把196.168.16.23 改成192.168.16.*????
------解决方案--------------------Text = Regex.Replace( "196.168.16.23 ", @ "(\d+.\d+.\d+.)(\d+) ", "$1* ");
------解决方案-------------------- string s= "196.168.16.23 ";
string[] temp=s.Split(new char[]{ '. '});
string tt=temp[0]+ ". "+temp[1]+ ". "+temp[2]+ ".* ";
------解决方案--------------------string srcIP = "196.168.16.23 ";
string tarIP = srcIP.Substring(0, srcIP.LastIndexOf( ". ")+1) + "* ";