" CreateRiaClientFilesTask"任务意外失败 [英] "CreateRiaClientFilesTask" task failed unexpectedly

查看:720
本文介绍了" CreateRiaClientFilesTask"任务意外失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

此错误已经开始尝试一些小的改动,以我的RIA领域的服务,这是Silverlight的网站应用程序内托管后,建立我的VS 2010的Silverlight项目时存在的。似乎没有理由为这个错误,我无法理解的拒绝访问错误的一部分。

This error has started occuring when attempting to build my VS 2010 Silverlight project after some minor changes to my RIA domain services, which are hosted within the Silverlight website application. There appears to be no reason for this error and I cannot understand the access denied part of the error.

东西我曾尝试:

1)解决方案,并重新构建所有项目的全面清理
2)所有临时ASP.Net文件的删除从框架文件夹
3)从类库失败项目属性,干净,重新构建,然后重新添加链接RIA服务的链接RIA服务拆卸

1) Full clean of all projects in the solution and re-build 2) Deletion of all temporary ASP.Net files from the framework folder 3) Removal of linked RIA services from project properties from the class library that is failing, clean, re-build and then re-add linked RIA services

在哪里可以从这里去任何意见将是多少AP preciated:

Any advice on where to go from here would be much appreciated:

错误21CreateRiaClientFilesTask任务意外失败。
System.Web.HttpException(0X80004005):无法加载文件或程序集商务,版本= 1.0.0.0,文化=中性公钥= null或它的一个依赖。访问被拒绝。 ---> System.Configuration.ConfigurationErrorsException:无法加载文件或程序集商务,版本= 1.0.0.0,文化=中性公钥= null或它的一个依赖。访问被拒绝。 ---> System.IO.FileLoadException:无法加载文件或程序集商务,版本= 1.0.0.0,文化=中性公钥= null或它的一个依赖。访问被拒绝。 ---> System.IO.FileLoadException:无法加载文件或程序集商务或它的一个依赖。访问被拒绝。

Error 21 The "CreateRiaClientFilesTask" task failed unexpectedly. System.Web.HttpException (0x80004005): Could not load file or assembly 'Business, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Access is denied. ---> System.Configuration.ConfigurationErrorsException: Could not load file or assembly 'Business, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Access is denied. ---> System.IO.FileLoadException: Could not load file or assembly 'Business, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Access is denied. ---> System.IO.FileLoadException: Could not load file or assembly 'Business' or one of its dependencies. Access is denied.

---内部异常堆栈跟踪的结尾---
   在System.Reflection.RuntimeAssembly._nLoad(的AssemblyName文件名,字符串codeBase类,证据assemblySecurity,RuntimeAssembly locationHint,StackCrawlMark&安培; stackMark,布尔throwOnFileNotFound,布尔forIntrospection,布尔SUP pressSecurityChecks)
   在System.Reflection.RuntimeAssembly.nLoad(的AssemblyName文件名,字符串codeBase类,证据assemblySecurity,RuntimeAssembly locationHint,StackCrawlMark&安培; stackMark,布尔throwOnFileNotFound,布尔forIntrospection,布尔SUP pressSecurityChecks)
   在System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(的AssemblyName assemblyRef,证据assemblySecurity,StackCrawlMark&安培; stackMark,布尔forIntrospection,布尔SUP pressSecurityChecks)
   在System.Reflection.RuntimeAssembly.InternalLoad(字符串assemblyString,证据assemblySecurity,StackCrawlMark&安培; stackMark,布尔forIntrospection)
   在System.Reflection.Assembly.Load(字符串assemblyString)
   在System.Web.Configuration.CompilationSection.LoadAssemblyHelper(字符串的AssemblyName,布尔starDirective)
   ---内部异常堆栈跟踪的结尾---
   在System.Web.Configuration.CompilationSection.LoadAssemblyHelper(字符串的AssemblyName,布尔starDirective)
   在System.Web.Configuration.CompilationSection.LoadAllAssembliesFromAppDomainBinDirectory()
   在System.Web.Configuration.CompilationSection.LoadAssembly(程序集信息AI)
   在System.Web.Compilation.BuildManager.GetReferencedAssemblies(CompilationSection compConfig)
   在System.Web.Compilation.BuildManager.Get preStartInitMethodsFromReferencedAssemblies()
   在System.Web.Compilation.BuildManager.Call preStartInitMethods()
   在System.Web.Hosting.HostingEnvironment.Initialize(ApplicationManager的AppManager,IApplicationHost APPHOST,IConfigMapPathFactory configMapPathFactory,HostingEnvironmentParameters hostingParameters,PolicyLevel policyLevel,异常appDomainCreationException)
   在System.Web.Compilation.ClientBuildManager.EnsureHostCreated()
   在System.Web.Compilation.ClientBuildManager.CreateObject(类型类型,布尔failIfExists)
   在Microsoft.ServiceModel.DomainServices.Tools.CreateRiaClientFilesTask.CreateSharedTypeService(ClientBuildManager clientBuildManager,IEnumerable`1 serverAssemblies,ILogger记录仪)
   在Microsoft.ServiceModel.DomainServices.Tools.CreateRiaClientFilesTask.GenerateClientProxies()
   在Microsoft.ServiceModel.DomainServices.Tools.CreateRiaClientFilesTask.ExecuteInternal()
   在Microsoft.ServiceModel.DomainServices.Tools.RiaClientFilesTask.Execute()
   在Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
   在Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost,TaskLoggingContext taskLoggingContext,TaskHost taskHost,ItemBucket斗,TaskExecutionMode howToExecuteTask,布尔和放大器; taskResult)Insurer.Analytics.Common

--- End of inner exception stack trace --- at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks) at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks) at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection, Boolean suppressSecurityChecks) at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) at System.Reflection.Assembly.Load(String assemblyString) at System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) --- End of inner exception stack trace --- at System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) at System.Web.Configuration.CompilationSection.LoadAllAssembliesFromAppDomainBinDirectory() at System.Web.Configuration.CompilationSection.LoadAssembly(AssemblyInfo ai) at System.Web.Compilation.BuildManager.GetReferencedAssemblies(CompilationSection compConfig) at System.Web.Compilation.BuildManager.GetPreStartInitMethodsFromReferencedAssemblies() at System.Web.Compilation.BuildManager.CallPreStartInitMethods() at System.Web.Hosting.HostingEnvironment.Initialize(ApplicationManager appManager, IApplicationHost appHost, IConfigMapPathFactory configMapPathFactory, HostingEnvironmentParameters hostingParameters, PolicyLevel policyLevel, Exception appDomainCreationException) at System.Web.Compilation.ClientBuildManager.EnsureHostCreated() at System.Web.Compilation.ClientBuildManager.CreateObject(Type type, Boolean failIfExists) at Microsoft.ServiceModel.DomainServices.Tools.CreateRiaClientFilesTask.CreateSharedTypeService(ClientBuildManager clientBuildManager, IEnumerable`1 serverAssemblies, ILogger logger) at Microsoft.ServiceModel.DomainServices.Tools.CreateRiaClientFilesTask.GenerateClientProxies() at Microsoft.ServiceModel.DomainServices.Tools.CreateRiaClientFilesTask.ExecuteInternal() at Microsoft.ServiceModel.DomainServices.Tools.RiaClientFilesTask.Execute() at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute() at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask, Boolean& taskResult) Insurer.Analytics.Common

推荐答案

刚刚有同样的问题 - 原来的东西改变了对临时ASP.NET文件文件夹的权限。这很容易测试。点击ASP.Net配置在Solution Explorer中的项目名.web。它很可能会抛出一个访问被拒绝的错误,并指出你的临时asp.net文件的文件夹。如果是这样,在你的名.web项目开放的web.config文件,并添加一个tempDirectory指令编译,像这样:

Just had the same problem - turns out that something changed the permissions on the "Temporary ASP.NET Files" folder. It's easy to test. Click the ASP.Net Configuration in solution explorer for the .web project. It'll likely throw an access denied error and point you to the temp asp.net files folder. If so, open web.config in your .web project and add a tempDirectory directive to compilation, like so:

<configuration>
    <system.web>
        <compilation debug="true" targetFramework="4.0" tempDirectory="C:\<SomeDirectoryYouFullyControl>\Temporary ASP.Net Files" />
    </system.web>

您的重建项目名.web和更新您的Silverlight项目的服务引用。

Rebuild your .web project and update your service reference in your silverlight project.

这篇关于&QUOT; CreateRiaClientFilesTask&QUOT;任务意外失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆