Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/asp.net-mvc/15.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Asp.net mvc Vs2010 MvcBuildViews未启动_Asp.net Mvc_Visual Studio 2010 - Fatal编程技术网

Asp.net mvc Vs2010 MvcBuildViews未启动

Asp.net mvc Vs2010 MvcBuildViews未启动,asp.net-mvc,visual-studio-2010,Asp.net Mvc,Visual Studio 2010,Vs2008中的此项目针对.NET3.5,用于编译视图 Vs2010以.net 4.0为目标以下视图代码未被视为错误,并且我还没有找到侦听mvcBuildview跟踪/调试输出的方法: <%{ %> 未拾取完全不匹配的代码块声明,也未拾取从不存在的命名空间/类继承的部分视图 <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'DebugWithBuildViews|AnyCPU' "

Vs2008中的此项目针对.NET3.5,用于编译视图

Vs2010以.net 4.0为目标以下视图代码未被视为错误,并且我还没有找到侦听mvcBuildview跟踪/调试输出的方法:

<%{ %>

未拾取完全不匹配的代码块声明,也未拾取从不存在的命名空间/类继承的部分视图

<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'DebugWithBuildViews|AnyCPU' ">

<!--<BaseIntermediateOutputPath>bin/intermediate</BaseIntermediateOutputPath>-->
<!--<MvcBuildViews Condition=" '$(Configuration)' == 'DebugWithBuildViews' ">true</MvcBuildViews>-->
<EnableUpdateable>false</EnableUpdateable>
<MvcBuildViews>true</MvcBuildViews>
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<DebugType>full</DebugType>
<PlatformTarget>AnyCPU</PlatformTarget>
<CodeAnalysisUseTypeNameInSuppression>true</CodeAnalysisUseTypeNameInSuppression>
<CodeAnalysisModuleSuppressionsFile>GlobalSuppressions.cs</CodeAnalysisModuleSuppressionsFile>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
<RunCodeAnalysis>true</RunCodeAnalysis>
 </PropertyGroup>

假的
真的
真的
箱子
调试;痕迹
满的
任意CPU
真的
GlobalSuppressions.cs
促使
AllRules.ruleset
真的
我的预构建:

<Target Name="BeforeBuild">
<WriteLinesToFile File="$(OutputPath)\env.config" Lines="$(Configuration)" Overwrite="true">
</WriteLinesToFile>

我的后建:

<Target Name="AfterBuild" Condition="'$(MvcBuildViews)'=='true'">
<!--<BaseIntermediateOutputPath>[SomeKnownLocationIHaveAccessTo]</BaseIntermediateOutputPath>-->
<Message Importance="high" Text="Precompiling views" />
  <!--<AspNetCompiler VirtualPath="temp" PhysicalPath="$(ProjectDir)..\$(ProjectName)" />-->
<!--<AspNetCompiler VirtualPath="temp" />-->
<!--PhysicalPath="$(ProjectDir)\..\$(ProjectName)"-->

错误410在应用程序级别之外使用注册为allowDefinition='MachineToApplication'的节是错误的。此错误可能是由于未在IIS中将虚拟目录配置为应用程序造成的。web.config 100


清理项目通常有助于防止此错误。

请参阅@Maslow:您是否得到过有关此问题的答案?“我也有同样的问题,根本无法解决。”约书亚·弗兰克非常肯定我没有t@Maslow:叹气。这么简单和必要的功能,我不能让它工作,无论我做什么!