Unity2018 Open C# Project Error
错误日志
升级到Unity2018之后,使用 Open C# Project 打开VS工程,出现报错,无法启动VS。
错误日志如下:
ArgumentException: Value does not fall within the expected range.
SyntaxTree.VisualStudio.Unity.Bridge.CompilationUnit.LanguageOf (SyntaxTree.VisualStudio.Unity.Bridge.CompilationUnit unit)
SyntaxTree.VisualStudio.Unity.Bridge.CompilationUnit.CompilationUnits (System.String method)
SyntaxTree.VisualStudio.Unity.Bridge.CompilationUnit.CompilationUnits ()
SyntaxTree.VisualStudio.Unity.Bridge.ProjectSystem.UnitySolutionBuilder..ctor ()
SyntaxTree.VisualStudio.Unity.Bridge.ProjectSystem.UnitySolutionBuilder.CreateSolutionFromAssetDatabase ()
SyntaxTree.VisualStudio.Unity.Bridge.ProjectFilesGenerator.GenerateProject ()
SyntaxTree.VisualStudio.Unity.Bridge.ProjectFilePostprocessor.OnPreGeneratingCSProjectFiles ()
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)
Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation.
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:232)
System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MethodBase.cs:115)
UnityEditor.AssetPostprocessingInternal.OnPreGeneratingCSProjectFiles () (at C:/buildslave/unity/build/Editor/Mono/AssetPostprocessor.cs:194)
UnityEditor.VisualStudioIntegration.SolutionSynchronizer.Sync () (at C:/buildslave/unity/build/Editor/Mono/VisualStudioIntegration/SolutionSynchronizer.cs:207)
UnityEditor.SyncVS.SyncSolution () (at C:/buildslave/unity/build/Editor/Mono/SyncProject.cs:190)
UnityEditor.SyncVS.SyncAndOpenSolution () (at C:/buildslave/unity/build/Editor/Mono/SyncProje
Unity Down Assistant
在Unity的Download Assistant中进行下载VS组件

vs_Enterprise安装Unity组件
在vs_Enterprise.exe 中安装unity的组件也是失败


其它排查方法
怀疑是Unity的问题,重新安装 Unity,问题无法解决。
更换其它版本的unity,比如2018.2.9f1,问题无法解决。
解决方案
如果是VS2015,则可以通过下载新版本的Visual Studio Tools For Unity 进行更新。(公司机器测试通过)
如果是VS2013,下载新版本的Visual Studio Tools For Unity 更新后也是失败(家里机器)。
更新VS2017,问题得到解决。
Unity2018 Open C# Project Error的更多相关文章
- QT编译错误:Project ERROR: This example requires Qt to be configured with -opengl desktop
学习QT场景视图,对一个Boxes的例子比较感兴趣,于是去编译学习,结果编译不能通过(使用的是QT5.12): Project ERROR: This example requires Qt to b ...
- 解决 “Project ERROR: Unknown module(s) in QT: webengine”以及“Your MaintenanceTool appears to be older than 3.0.2. .” 的办法
1.环境 Windows10,Qt5.8.0 2.问题描述 需要使用到WebEngineView组件,在工程.pro中增加webengine后,Qt Creator应用程序输出中打印了 Project ...
- VS2008 Project : error PRJ0019: 某个工具从以下位置返回了错误代码: "正在执行生成后事件..."解决方案
右键工程属性 -> 配置属性 -> 生成事件 ->生成后事件,命令行中的路径加上双引号,如 copy $(ProjectDir)\export\win32\Debug\$(Proje ...
- QT 报错:Project ERROR: Xcode not set up properly. You may need to confirm the license agreement by running /usr/bin/xcodebuild.
1.打开终端,输入指令并按回车键: sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer 2.如果电脑设置有密码,终 ...
- [ERROR ]Failed to execute goal org.codehaus.mojo:flatten-maven-plugin:1.1.0:flatten (flatten) on project
今天在启动项目的时候,莫名的Maven install命令的时候出现错误 错误提示:Failed to execute goal org.codehaus.mojo:flatten-maven-plu ...
- error RC1205: invalid code page
Get followings error and warnings when building project: error RC1205: invalid code pagewarning C400 ...
- vapor 生成xcode project 产生的错误解决方式
运行vapor xcode时报错: Could not generate Xcode project: error: terminated(72): xcrun --sdk macosx --find ...
- Git you are not allowed to push code to protected branches on this project?
error: You are not allowed to push code to protected branches on this project....error: failed to pu ...
- VS2015+cordova+ionic安装配置
VS2015已经出了正式版,想用来试一下cordova方面的开发.最近在看ionic这个框架,于是想能在VS2015里编辑js就好了. 下面说一下蛋疼的安装配置过程. 一.安装VS2015及Andro ...
随机推荐
- Linux中断程序命令
在运行 python 脚本的时候想要中断程序,发现如下情况: ctrl+c 居然无法中断程序! 这时候尝试 ctrl+d 还是毫无效果,最后尝试 ctrl+\: 查看该程序是否还在运行 ps aux ...
- ASP.NET Core 系列目录
目录: ASP.NET Core 2.0 : 一. 概述 ASP.NET Core 2.0:二. 开发环境 ASP.NET Core 2.0 : 三. 项目结构 ASP.NET Core 2.0 : ...
- .NET Core实战项目之CMS 第三章 入门篇-源码解析配置文件及依赖注入
作者:依乐祝 原文链接:https://www.cnblogs.com/yilezhu/p/9998021.html 写在前面 上篇文章我给大家讲解了ASP.NET Core的概念及为什么使用它,接着 ...
- laravel的消息队列剖析
laravel的消息队列剖析 这篇来自于看到朋友转的58沈剑的一篇文章:1分钟实现"延迟消息"功能 在实际工作中也不止遇见过一次这个问题,我在想着以前是怎么处理的呢?我记得当初在上 ...
- ElasticSearch(1)---Mysql同步数据到ElSearch
ElasticSearch同步Mysql 先讲项目需求:对于资讯模块添加搜索功能 这个搜索功能我就是采用ElasticSearch实现的,功能刚实现完,所以写这篇博客做个记录,让自己在记录下整个步骤和 ...
- Android--Tween补间动画
前言 Android除了支持逐帧动画之外,也提供了对补间动画的支持,补间动画就是指开发人员只需要指定动画的开始.动画结束的"关键帧",而动画变化的"中间帧"由系 ...
- [linux]为阿里云ECS(CentOS7)配置IPv6地址
环境为:ECS"经典网络"类型 步骤: 1. 编辑 /etc/sysctl.conf 文件,将其中三条禁用IPv6的设置更改为: net.ipv6.conf.all.disable ...
- ES6躬行记(12)——数组
ES6为数组添加了多个新方法,既对它的功能进行了强化,也消除了容易产生歧义的语法. 一.静态方法 1)of() ES6为Array对象新增的第一个静态方法是of(),用于创建数组,它能接收任意个参数, ...
- Java读取Excel指定列的数据详细教程和注意事项
本文使用jxl.jar工具类库实现读取Excel中指定列的数据. jxl.jar是通过java操作excel表格的工具类库,是由java语言开发而成的.这套API是纯Java的,并不依赖Windows ...
- C# 通过进程名/进程Id 操作窗口/程序
1. 判断窗口是否存在 private bool IsWindowExist(IntPtr handle) { ) != IntPtr.Zero) && IsWindowVisible ...