TCP发送请求,启用后台线程侦听接收TcpClient传入请求
static void Main(string[] args) { Thread thread = new Thread(new ThreadStart(Listen)); thread.Start(); } /// <summary> /// 侦听接收TcpClient发送来的数据 /// </summary>...
static void Main(string[] args) { Thread thread = new Thread(new ThreadStart(Listen)); thread.Start(); } /// <summary> /// 侦听接收TcpClient发送来的数据 /// </summary>...
private string GetHTML() { System.Net.WebClient client = new WebClient(); Stream strm = client.OpenRead("http://www.mayb.cn"); StreamReader sr = new StreamReader(str...
ThoughtWorks.QRCode.dll (5.92 mb)下载QRCodeHandler.ashx 代码如下<%@ WebHandler Language="C#" Class="QRCodeHandler" %> using System; using System.Web; using ThoughtWorks.QRCode...
public static string GetHTML(string url) { ASCIIEncoding encoding = new ASCIIEncoding(); HttpWebRequest myRequest = (HttpWebRequest)WebRequ...
<%# Container.ItemIndex %>
/// <summary> /// 限制只能输入数字 /// </summary> /// <param name="sender"></param> /// <param name="e"></param&...
if (Convert.ToInt32(e.KeyChar) == 8) { e.Handled = false; } else { Regex rex = new Regex(@"...
aspx是页面文件ascx是用户控件,用户控件必须嵌入到aspx中才能使用。aspx:页面asmx:Web服务ascx:用户控件config:配置使用ascx目的就是为了提高某部分功能的重复利用.sln:解决方案文使用ascx目的就是为了提高某部分功能的重复利用件,为解决方案资源管理器提供显示管理文件的图形接口所需的信息。.csproj:项目文件,创建...
Process.Start(Assembly.GetExecutingAssembly().Location); Process.GetCurrentProcess().Kill();
Response.Buffer = true; Response.ExpiresAbsolute = DateTime.Now.AddDays(-1); Response.Cache.SetExpires(DateTime.Now.AddDays(-1)); Response.Expires = 0; Response.CacheCon...