Sub read_allmessage() '读取关于该客户的所有对话        If data_link() = False Then
            '出错
            Exit Sub        End If        adpt = New SqlDataAdapter("[read_allmessage]", connhaiwang)
        adpt.SelectCommand.CommandType = CommandType.StoredProcedure        adpt.SelectCommand.Parameters.Add("@customer_id", SqlDbType.Int)
        adpt.SelectCommand.Parameters("@customer_id").Value = Request.QueryString("customer_id")        Dim table As DataTable
        table = New DataTable
        Try            adpt.Fill(table)        Catch ex As Exception            connhaiwang.Close()            Exit Sub        End Try        Dim i As Integer        txt1.Text = ""        For i = 0 To table.Rows.Count - 1            txt1.Text = txt1.Text & table.Rows(i)("customer_content") & vbCrLf        Next
        connhaiwang.Close()    End Sub
我想每隔10秒执行一次上述操作

解决方案 »

  1.   

    <meta http-equiv="Refresh" content="1000;URL=/expert/deeptree/contentbar.asp">
    1000是
    秒,url是地址
      

  2.   

    使用SQL Server Job。数据库的事情用数据库代码去做。
      

  3.   

    郁闷
    你究竟要做什么哦
    是要返回结果到用户界面还是只是刷表?
    只刷表的话,很简单,做一个自动启动的服务
    进入死循环 然后让Thread 睡觉(sleep)10秒然后再刷就是了!
    要控制也可以,做一个可调用的异步web service,线程间通信到msdn上看哈
      

  4.   

    相信这个对你有作用的
    http://blog.csdn.net/net_lover/archive/2003/08/27/6943.aspx