![](https://img-blog.csdnimg.cn/20201014180756923.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
后端小方法
菜牙9527
这个作者很懒,什么都没留下…
展开
-
C# 起线程方式
class Program { public static void ThreadFunction(object state) { string str = state as string; Console.WriteLine("当前线程的唯一标识符=" + Thread.CurrentThread.ManagedThreadId); Console.WriteLine("当前线程的参数=" + str); } static v原创 2020-08-05 15:05:02 · 152 阅读 · 0 评论 -
C# 一个获取请求IP的方法
C# 一个获取请求IP的方法 废话不多说,直接上方法。 ServerVariables集合有兴趣的可以去查一下; /// <summary> /// 取得客户端真实IP。如果有代理则取第一个非内网地址 /// </summary> /// <returns></returns> public string GetIP(HttpContext _Current) { string result = String.Empty; /原创 2020-08-01 15:28:48 · 2158 阅读 · 0 评论