我用VS2012在Nuget中安装Signalr之后报错

“/”应用程序中的服务器错误。


The following errors occurred while attempting to load the app.
- No assembly found containing an OwinStartupAttribute.
- No 'Configuration' method was found in class 'Microsoft.VisualStudio.Web.PageInspector.Runtime.Startup, Microsoft.VisualStudio.Web.PageInspector.Runtime, Version=1.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
To disable OWIN startup discovery, add the appSetting owin:AutomaticAppStartup with a value of "false" in your web.config.
To specify the OWIN startup Assembly, Class, or Method, add the appSetting owin:AppStartup with the fully qualified startup class or configuration method name in your web.config.

解决办法:

The template produces such a class:

using System;
using System.Threading.Tasks;
using Microsoft.Owin;
using Owin; [assembly: OwinStartup(typeof(WebApiOsp.App_Start.Startup))] namespace WebApiOsp.App_Start
{
public class Startup
{
public void Configuration(IAppBuilder app)
{
// For more information on how to configure your application, visit http://go.microsoft.com/fwlink/?LinkID=316888
app.MapSignalR();
}
}
}

或者:

Web.config添加

<appSettings>
<add key="owin:AutomaticAppStartup" value="false" />
</appSettings>

http://stackoverflow.com/questions/20068075/owin-startup-class-missing

我用VS2012在Nuget中安装Signalr之后报错的更多相关文章

  1. 关于pycharm中安装第三方库时报错的解决办法(一)

    记录自己的生活!   一.事发背景 在pycharm中直接安装第三方库时因为版本问题总是无法安装成功,事情不大,但是很重要.   二.经过 最开始我自己电脑上安装了Python3.6和Python2. ...

  2. 安装xampp之后报错XAMPP: Starting Apache...fail.

    1.安装完成xampp之后报错: 2.网上查到的解决办法是:输入sudo apachectl stop 之后再次启动lampp,问题得以解决: 过两天发现问题并没有解决: ①在网上查询发现是因为端口被 ...

  3. vue 中安装使用sass 报错遇到的问题整理

    不出错的情况下,正常安装: 1.安装包: npm install node-sass --save-dev npm install sass-loader --save-dev (sass-loade ...

  4. [报错集]ubuntu中安装oracle java报错

    1.因为版本更新,JAVA15以前的版本都已经没办法下载了,所以要使用oracle java必须使用最近的java15 $ sudo apt-get install oracle-java15-ins ...

  5. centos7安装anaconda之后报错:rpm: /home/wyl/anaconda3/lib/liblzma.so.5: version `XZ_5.1.2alpha' not found (required by /lib64/librpmio.so.3)

    1.报错 参考:https://stackoverflow.com/questions/47633870/rpm-lib64-liblzma-so-5-version-xz-5-1-2alpha-no ...

  6. 2019-11-24:postgresql数据库安装,最后报错failed to load SQLModule 问题的解决方案

    安装环境:Windows 10 问题描述:Failed to load sql modules into the database cluster 原因在于 Postgresql 没有安装完全. 解决 ...

  7. MVC中使用SignalR打造酷炫实用的即时通讯功能附源码

    前言,现在这世道写篇帖子没个前言真不好意思发出来.本贴的主要内容来自于本人在之前项目中所开发的一个小功能,用于OA中的即时通讯.由于当时走的太急,忘记把代码拿出来.想想这已经是大半年前的事情了,时间过 ...

  8. MVC中使用SignalR

    MVC中使用SignalR打造酷炫实用的即时通讯功能附源码   前言,现在这世道写篇帖子没个前言真不好意思发出来.本贴的主要内容来自于本人在之前项目中所开发的一个小功能,用于OA中的即时通讯.由于当时 ...

  9. 如何在web api中使用SignalR

    说明: 在webapi中使用signalr,使用IIS 环境: vs2012, .net4.5 第一步:建web api项目 第二步:nuget导入signalr Install-Package Mi ...

随机推荐

  1. A - 迷宫问题

      Time Limit:1000MS     Memory Limit:65536KB     64bit IO Format:%I64d & %I64u Submit Status Pra ...

  2. jquery CRUD一个元素class属性

    jquery增加,移除,修改一个html标签的class名字 一个标签可以指定多个class 1.         增加一个class: $(".default").addClas ...

  3. redis-cluster 单个节点不可用

    背景: 公司的音视频 盗版检测业务,使用redis-cluster作为 key-value 数据库, 使用张图片的 特征hash值作key.因为数据量太大,机器有限,集群内没有slaver 问题描述 ...

  4. RealProxy深入

    Program.cs class Program { static void Main(string[] args) { NoMethodLogging(); Console.WriteLine(&q ...

  5. 【PHP开发】国外程序员收集整理的 PHP 资源大全

    依赖管理 依赖和包管理库 Composer/Packagist:一个包和依赖管理器 Composer Installers:一个多框架Composer库安装器 Pickle:一个PHP扩展安装器 其他 ...

  6. Array.splice()理解记忆

    var arr = [0,1,2,3,4,5,6,7,8,9]; arr.splice(0,0,"添加项1"); //arr => ["添加项",0,1, ...

  7. pyodbc不支持使用%,应该使用?

    pyodbc不支持使用%,应该使用? 如: Sql插入语句cur.execute("INSERT INTO bb VALUES (?,?,?)","s",&qu ...

  8. SQL Server COM 组件创建实例失败

    SQL Server COM 组件创建实例失败   SQL2008数据库总会出现从 IClassFactory 为 CLSID 为 {17BCA6E8-A95D-497E-B2F9-AF6AA4759 ...

  9. 特别实用而且功能强大的attributedText属性

    UILabel *sendNameLB = [[UILabel alloc]initWithFrame:CGRectMake(, , , )]; NSString * string = @" ...

  10. CE创建进程和线程

    创建进程: HWND hWnd = NULL; PROCESS_INFORMATION pi = {}; if(NULL==hWnd) { hWnd=FindWindow(NULL,_T(" ...