728x90
반응형
            string localIP = String.Empty;

            foreach (IPAddress ip in Dns.GetHostEntry(Dns.GetHostName()).AddressList)
            {
                if (ip.AddressFamily.ToString().ToUpper().Equals("INTERNETWORK"))
                    localIP = ip.ToString();
            }

            return localIP;

반응형

+ Recent posts