asp.net在事件中启动线程来打开一个页面的实现方
网络编程 2021-07-04 22:41www.168986.cn编程入门
点击一个按钮做两件事情,一件需要点击按钮马上完成,另一件事情是点击按钮后做其他事情,不会的朋友一起来看看狼蚁网站SEO优化是如何实现的
在页面点击一个按钮,其目的是在按钮中做两件事情,一件需要点击按钮马上完成,另一件事情是点击按钮后做其他事情。如果按顺序一次做完感觉特别耗时,狼蚁网站SEO优化简单罗列一下。
protected void Button1_Click(object sender, EventArgs e) { Label1.Text = TextBox1.Text; //在这做第一件事情 dowork(); //做完后马上启动线程 System.Threading.Thread thread = new System.Threading.Thread(new System.Threading.ThreadStart(ThreadChild)); thread.Start(); }
线程中处理完后打开一个窗口
public void ThreadChild() { Label2.Text = DateTime.Now.ToString(); //Response.Write(""); //响应http必然报错 //Response.Write("<script>window.open('login.aspx','','');</script>"); //通过注册即可打开窗口 Page.RegisterStartupScript("", "<script>window.open('login.aspx','','');</script>"); }
编程语言
- 机械手焊接机器人编程 机械手焊接设备编程
- vb数据库编程实例,vb做数据库
- tiobe世界编程语言排行榜,全球编程语言排行
- 成都java编程培训 成都it编程培训中心
- 编程基础培训,编程基础知识培训
- flash游戏编程基础教程,flash游戏开发教程
- 不会英语能学编程吗 不会英语可以学程序员吗
- 爱心代码编程C语言 爱心代码编程c语言公式
- c语言编程学习入门 c语言编程快速入门
- 西门子plc编程培训 西门子plc编程培训班
- 哪里可以学编程 台州哪里可以学编程
- 少儿编程哪个好 少儿编程哪个品牌好
- 编程是什么意思,图形编程是什么意思
- c语言编程软件下载,c语言编程软件在哪下载
- java编程软件下载,java编程下载手机版
- ug编程培训学校,ug编程培训教程