<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm2.aspx.cs" Inherits="WebApplication2.WebForm2" %>
<!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">
    <style>
        .abc
        {
            background-color: Green;
        }
    </style>
    <title></title>
    <script src="Scripts/jquery-1.4.1.js" type="text/javascript"></script>
    <script type="text/javascript">
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
   
    <ContentTemplate>
   
    <asp:Timer ID="Timer1" runat="server" Interval="1000" ontick="Timer1_Tick"></asp:Timer>
       <div>
        <asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
        <asp:Label ID="Label2" runat="server" Text="Label"></asp:Label>
        <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="~/TestNetwork.aspx">HyperLink</asp:HyperLink>
        <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False">
            <Columns>
                <asp:BoundField DataField="CPU" HeaderText="CPU" />
                <asp:TemplateField HeaderText="Memory">
                    <ItemTemplate>
                        <%-- <asp:Label ID="Label4" runat="server" Text='<%# Eval("Memory") %>'></asp:Label>--%>
                        <a href="WebForm1.aspx?CPU=<%# Eval("Memory") %>">
                            <%# Eval("Memory") %></a>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="AMemory">
                    <ItemTemplate>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Nemory">
                    <ItemTemplate>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Network">
                    <ItemTemplate>
                    </ItemTemplate>
                </asp:TemplateField>
            </Columns>
        </asp:GridView>
    </div>
    </ContentTemplate>
   
    </asp:UpdatePanel>
 
    </form>
</body>
</html>
--------------------------------------------------------------------------------
 
 
   protected void Timer1_Tick(object sender, EventArgs e)
        {
            getdata();
        }

Gridview 每秒刷新数据的更多相关文章

  1. echarts - 折线图 - 每秒刷新数据并显示

    function randomData() { now = new Date(+now + oneDay); value = value + Math.random() * 21 - 10; var ...

  2. Android PullToRefresh (GridView 下拉刷新上拉加载)

    做这个需要自己去git hub上下载个pull-to-refresh 里面有个library为依赖包自己导到自己的项目中 (下载地址:https://github.com/chrisbanes/And ...

  3. js中setInterval与setTimeout用法 实现实时刷新每秒刷新

    setTimeout 定义和用法:  setTimeout()方法用于在指定的毫秒数后调用函数或计算表达式.     语法:  setTimeout(code,millisec)     参数:    ...

  4. SQL实现类似于自动刷新数据的功能

    有时需要在SQL中,定时刷新某张表,比如说是要定时查询某张表的行数,通常做法就是手动的按F5去执行来刷新数据.但是如果这个定时查询历时较长,10分钟,或半小时,手动的话肯定是要崩溃了.貌似SQL没有像 ...

  5. jsTree 的简单用法--异步加载和刷新数据

    首先这两个文件是必须要引用的,还有就是引用 jQuery 文件就不说了: <link href="/css/plugins/jsTree/style.min.css" rel ...

  6. iOS - UIRefreshControl 刷新数据

    前言 NS_CLASS_AVAILABLE_IOS(6_0) __TVOS_PROHIBITED @interface UIRefreshControl : UIControl 1.UIRefresh ...

  7. 解决JQuery中datatables设置隐藏显示列多次提交后台刷新数据的问题

    此次项目开发过程中用到了Jquery的Datatables插件,无疑他是数据列表展示,解决MVC中同步过程中先走控制器后返回视图,查询数据过程中无法提示等待的弊端, 而且他所提供的各种方法也都有较强的 ...

  8. POI刷新数据后的函数(公式)更新问题

    使用POI将Excel模板中的数据进行更新,这应该是很常见的操作 下面就贴上我的一小段代码 public class ModifyExcel { /** * @param fileName Excel ...

  9. C# 数据库dataGridView刷新数据和主外键判断

    本文主要讲诉在使用VS2012+SQL Server数据库做系统中,通常会遇到几个问题.使用dataGridView控件在修改.删除.插入数据后,怎样刷新数据显示操作后的结果.同时在对数据操作时通常会 ...

随机推荐

  1. 使用jQuery Ajax功能的时候需要注意的一个问题

    每次jquery的Ajax请求都会创建一个xmlHttprequest对象,理论上讲,长连接(页面需要和服务器保持长连接,而且在连接超时后需要重新请求连接)的请求是一个无限递归,请求数量是非常大的,但 ...

  2. 九度OJ 1166:迭代求立方根 (迭代)

    时间限制:1 秒 内存限制:32 兆 特殊判题:否 提交:3695 解决:1700 题目描述: 立方根的逼近迭代方程是 y(n+1) = y(n)*2/3 + x/(3*y(n)*y(n)),其中y0 ...

  3. Coursera公开课Functional Programming Principles in Scala习题解答:Week 2

    引言 OK.时间非常快又过去了一周.第一周有五一假期所以感觉时间绰绰有余,这周中间没有假期仅仅能靠晚上加周末的时间来消化,事实上还是有点紧张呢! 后来发现每堂课的视频还有相应的课件(Slide).字幕 ...

  4. 【zabbix】zabbix3.0部署手册

    1.环境准备 Centos 6.X 2.数据库准备 默认centos yum源中mysql包的版本号为5.1,为了能使zabbix 3.0能达到最好的性能效果,安装最新版的mysql数据库. yum ...

  5. Java for LeetCode 087 Scramble String

    Given a string s1, we may represent it as a binary tree by partitioning it to two non-empty substrin ...

  6. [2018-05-27]配置VSTS认证方式使用Personal Access Token

    本文介绍下如何配置VSTS(visual studio team service,其实就是微软SaaS版的TFS)通过Personal Access Token访问其下的Git代码库. 问题 使用gi ...

  7. Ruby操作数据库基本步骤

    1.rails g model university name:string 2.model has_many :colleges belongs_to :university has_one :us ...

  8. 【转】如何让虚拟目录里面的webconfig不继承网站的设置

    [转]http://www.cnblogs.com/Sue_/articles/2037556.html 必須在上一层虚拟目录(如根目录)所在的Web.config加上 如:<location ...

  9. 排序List集合

    这两天写代码过程中遇到一个需求,需要按照某个字段排序List集合,自己实现了一半,发现网上有个更好的版本,就采用了这个,记录下来. 使用这个工具类要注意一个就是 如果你按照age 字段排序,那么age ...

  10. Linux三种网络-vmware三种网络模式

    Host-Only 桥接 NAT VMware虚拟机三种联网方法及原理 一.Brigde——桥接:默认使用VMnet0 1.原理: Bridge 桥"就是一个主机,这个机器拥有两块网卡,分别 ...