UpdateProgress是一个进度显示条,加在AJAX里能显得更加的人性化(个人认为)。现在我们就开始吧: 第一.新建一个AJAX项目。在页面上加上ScriptManager,UpdatePanel,UpdateProgress,同时在UpdatePanel中加入一个Label,和Button。 第二:选中UpdateProgress的AssociatedUpdatePanelID设置为UpdatePanel1,完整的HTML代码如下:

<%@ Register     Assembly="AjaxControlToolkit"     Namespace="AjaxControlToolkit"     TagPrefix="ajaxToolkit"%> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server">     <title>无标题页</title> </head> <body>     <form id="form1" runat="server">     <div>         <asp:ScriptManager ID="ScriptManager1" runat="server">         </asp:ScriptManager>         </div>         <asp:UpdatePanel ID="UpdatePanel1" runat="server">             <ContentTemplate>                 &nbsp;<asp:Label ID="Label1" runat="server" Text="Label" Width="166px"></asp:Label>&nbsp;                 <br />                 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;                 <asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Button"/>             </ContentTemplate>         </asp:UpdatePanel>         <asp:UpdateProgress ID="testUp" runat=server AssociatedUpdatePanelID="UpdatePanel1">             <ProgressTemplate>                 progressing..             </ProgressTemplate>                    </asp:UpdateProgress>     </form> </body> </html>

第三,在BUTTON中加入点击事件,代码如下:

);         Label1.Text =  DateTime.Now.ToString();

主要是故意创建一个延迟,显示效果。 最后,运行就ok了

UpdateProgress使用的更多相关文章

  1. ASP.NET AJAX入门系列(7):使用客户端脚本对UpdateProgress编程

    在本篇文章中,我们将通过编写JavaScript来使用客户端行为扩展UpdateProgress控件,客户端代码将使用ASP.NET AJAX Library中的PageRequestManager, ...

  2. ASP.NET AJAX入门系列(6):UpdateProgress控件简单介绍

    在ASP.NET AJAX Beta2中,UpdateProgress控件已经从“增值”CTP中移到了ASP.NET AJAX核心中.以下两篇关于UpdateProgress的文章基本翻译自ASP.N ...

  3. Unity游戏内版本更新

    最近研究了一下游戏内apk包更新的方法. ios对于应用的管理比较严格,除非热更新脚本,不太可能做到端内大版本包的更新.然而安卓端则没有此限制.因此可以做到不跳到网页或应用商店,就覆盖更新apk包. ...

  4. iOS开发系列--音频播放、录音、视频播放、拍照、视频录制

    --iOS多媒体 概览 随着移动互联网的发展,如今的手机早已不是打电话.发短信那么简单了,播放音乐.视频.录音.拍照等都是很常用的功能.在iOS中对于多媒体的支持是非常强大的,无论是音视频播放.录制, ...

  5. iOS开发系列--网络开发

    概览 大部分应用程序都或多或少会牵扯到网络开发,例如说新浪微博.微信等,这些应用本身可能采用iOS开发,但是所有的数据支撑都是基于后台网络服务器的.如今,网络编程越来越普遍,孤立的应用通常是没有生命力 ...

  6. iOS空心圆下载进度指示器控件

    self.layer = [CAShapeLayer layer]; self.layer.frame = CGRectMake(, , , ); self.layer.position = self ...

  7. PHP 文件下载 显示进度条

    前台调用:js调用: function downloadfile(id,name,price,curcount_pricelimit){ Date.prototype.Format = functio ...

  8. c# 局域网文件传输实例

    一个基于c#的点对点局域网文件传输小案例,运行效果截图 //界面窗体 using System;using System.Collections.Generic;using System.Compon ...

  9. 小知识 安卓线程和ui

    *:first-child { margin-top: 0 !important; } body>*:last-child { margin-bottom: 0 !important; } /* ...

随机推荐

  1. 兼容ie\firefox\chrome的cursor

    cursor:hand 与 cursor:pointer 的效果是一样,都像手形光标. 但用FireFox浏览时才注意到使用cursor:hand在FireFox.chorme里并被支持.cursor ...

  2. [OpenSource]浅谈.Net和Java互相调用的三种方式

    在很多的大型系统开发中,开发工具往往不限制于同一种开发语言,而是会使用多种开发语言的混合型开发.目前Java和.Net都声称自己占85%的市场份额,不管谁对谁错,Java和.Net是目前应用开发的两个 ...

  3. CodeForcesGym 100753B Bounty Hunter II 二分图最小路径覆盖

    关键在建图 题解:http://www.cnblogs.com/crackpotisback/p/4856159.html 学习:http://www.cnblogs.com/jackiesteed/ ...

  4. 【JS】Intermediate7:jQuery:DOM API

    1.jQuery also makes performing actions on many elements at the same time simple 2.eg:$('.note').css( ...

  5. Java笔记(十七)……异常

    异常概述 异常是什么 是对问题的描述,将问题进行对象的封装 异常体系 Throwable |---Error |---Exception |---RuntimeException 异常体系的特点 异常 ...

  6. Fixing ssh login long delay

    原文:http://injustfiveminutes.com/2013/03/13/fixing-ssh-login-long-delay/ For a long time I had a prob ...

  7. WPF布局系统[转]

    转自:http://www.cnblogs.com/niyw/archive/2010/10/31/1863908.html前言 前段时间忙了一阵子Google Earth,这周又忙了一阵子架构师论文 ...

  8. Yii Listview 更新及搜索

    更新: http://my.oschina.net/shixiaobao17145/blog/130992 http://www.yiiframework.com/forum/index.php/to ...

  9. A Tour of Go Basic types

    Go's basic types are bool string int int8 int16 int32 int64 uint uint8 uint16 uint32 uint64 uintptr ...

  10. java字节流

    一. 字节输入流:InputStream(抽象类,所有字节输入流的超类) 1.FileInputStream:    文件输入流 FileInputStream fileIS = new FileIn ...