|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
SqlDependency OnChange event passed options in SqlNotificationInfoHi,
I used "using sqldependency in a windows application" example from MSDN with little modification on the database and table (use my own table). But it didn't work! The OnChange event handler did get fired but the SqlNotificationEventArgs e has the SqlNotificationInfo as "options". I found that this means "The SET options were not set appropriately at subscription time" from http://msdn2.microsoft.com/en-us/library/system.data.sqlclient.sqlnotificationinfo.aspx I tried using different connection string (also tried sa which is the owner of the database) still not working. The SQL command string is "SELECT DataType, DataOffset, DataSize from dbo.myDb where DataType > @DataType". Any insight for this will be really appreciated! |
|||||||||||||||||||||||