2

I need to build app with real-time SQL Server notifications (DB will be updated from external app). I use ASP.NET 5 (MVC 6). I want to use SqlDependency but it is unavailable in DNX Core 5.0 and I get an error:

CS0246  The type or namespace name 'SqlDependency' could not be found (are you 
missing a using directive or an assembly reference?)

What can I do to use SqlDependency in MVC 6.

tereško
  • 58,060
  • 25
  • 98
  • 150

1 Answers1

1

If you plan on running it on windows, you can just remove DNX Core and just use dnx46.

"frameworks": {
    "dnx46": {}
}
Nick De Beer
  • 5,232
  • 6
  • 35
  • 50
  • 1
    Where did you hook up the event, usually you put it in Application_Start, but asp.net mvc 6 doesn't have this event? //Start SqlDependency with application initialization SqlDependency.Start(connString); – DotnetShadow Jan 24 '16 at 01:41