c# - Type or namespace name 'OwinStartupAttribute' could not be found -
error
the type or namespace name 'owinstartupattribute' not found
type or namespace name 'owinstartup' not found
code
using microsoft.owin; using owin; [assembly: owinstartup(typeof(employee.web.models.startup))] namespace employee.web.models.startup { public class startup { public void configuration(iappbuilder app) { app.mapsignalr(); } } }
any appreciated.
using:
- .net 4.0
- mvc 4
- microsoft.aspnet.signalr.systemweb (1.1.0.0)
- microsoft.owin (2.1.0.0)
- microsoft.owin.host.systemweb (2.1.0.0)
- owin (1.0.0.0)
- visual studio 2013
installed singlar after referencing microsoft.owin using command install-package microsoft.aspnet.signalr -version 1.1.3
update: removed [assembly:..
, added in web.config: <add key="owin:appstartup" value="employee.web.models.startup" />
the error says
'owin.iappbuilder' not contain definition 'mapsignalr' , no extension method 'mapsignalr' accepting first argument of type 'owin.iappbuilder' found
create 1 class name startup you..
public class startup { public void configuration(iappbuilder app) { app.mapsignalr(); } }
in addition this, if startup class somehow not in default name space, add web config line area like: <add key="owin:appstartup" value="[namespace].startup" />
here more explenation.
Comments
Post a Comment