找不到窗口句柄
When doing this with the Aug CTP:
使用Aug CTP进行此操作时:
Response.Write("Page created: " + DateTime.Now.ToLongTimeString())
Dim connStr As String = ConfigurationManager.ConnectionStrings("AppConnectionString1").ConnectionString
System.Data.SqlClient.SqlDependency.Start(connStr) ‘BOOM
Dim connection As New SqlConnection(connStr)
Dim command As New SqlCommand("Select * FROM Customers", connection)
Dim sqlDependency As New SqlCacheDependency(command)
connection.Open()
GridView1.DataSource = command.ExecuteReader()
GridView1.DataBind()
Connection.Close()
Response.AddCacheDependency(sqlDependency)Response.Write(“创建的页面:” + DateTime.Now.ToLongTimeString()) 昏暗connStr作为字符串= ConfigurationManager.ConnectionStrings(“ AppConnectionString1”)。ConnectionString System.Data.SqlClient.SqlDependency.Start(connStr) 'BOOM 昏暗的连接作为新的SqlConnection(connStr) 将Dim命令作为新SqlCommand(“选择*来自客户”,连接) 昏暗的sqlDependency作为新的SqlCacheDependency(命令) connection.Open() GridView1.DataSource = command.ExecuteReader() GridView1.DataBind() Connection.Close() Response.AddCacheDependency(sqlDependency)
I got this:
我懂了:
Message="The conversation handle "206A971D-6F25-DA11-B22F-0003FF6FCCCA" is not found.
Invalid object name 'SqlQueryNotificationService - 41136655-4314-4536-a477-37156eb628db'."找不到消息=“对话句柄” 206A971D-6F25-DA11-B22F-0003FF6FCCCA“。 对象名称无效“ SqlQueryNotificationService-41136655-4314-4536-a477-37156eb628db”。
And fixed it with this "alter database Northwind set trustworthy on". Thanks Steve Smith!
并使用“在Northwind上设置值得信赖的alter database ”来修复它。 谢谢史蒂夫·史密斯!
翻译自: https://www.hanselman.com/blog/sqldependancystart-and-conversation-handle-not-found
找不到窗口句柄