Skip to main content

Greetings,


 


The application I am working on is an web application developed on .Net framework 2.0.


I have a developer system in which K2 blackpearl and Visual studio is installed, K2 process is developed on the same system. I took a build in the developer seat and deployed it on development server and found the following problem.


 


I searched for the solution on google and found the folloing links


http://blogs.msdn.com/eldar/archive/2006/06/07/621501.aspx


http://archworx.wordpress.com/2007/10/17/resolution-to-exception-from-hresult-0x800736b1/


 


Read the explaination on reading the article above:


I am not able to find the dependend dll or the mismatch version of the dll on the system. As I have added the reference of K2 assembly from my application folder and not GAC the version should be same. I know this is a application/infrastructure specific issue, so request you to please throw some random ideas that you might get to solve the problem. Or solution if you have come across any such problem.


I had faced simillar issue in my earlier project. This problem came after updating .Net framework 3.0 to SP1. I installed the .Net framework 3.5 and it started working fine, but I am unaware of the thing which made it working. I cannot ask the infrastructure team to install the .Net framework 3.5 as it is not the application requriement.


 


 


Error


______________________________________________________________________________


Server Error in '/AppName' Application.





This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem. (Exception from HRESULT: 0x800736B1)


Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Runtime.InteropServices.COMException: This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem. (Exception from HRESULT: 0x800736B1)

Source Error:



An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.




Stack Trace:



 

0COMException (0x800736b1): This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem. (Exception from HRESULT: 0x800736B1)]

 

0FileLoadException: Could not load file or assembly 'SourceCode.HostClientAPI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=16a2c5aaaa1b130d' or one of its dependencies. This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem. (Exception from HRESULT: 0x800736B1)]

   System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection) +0

   System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection) +54

   System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) +211

   System.Reflection.Assembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) +141

   System.Reflection.Assembly.Load(String assemblyString) +25

   System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) +32

 

tConfigurationErrorsException: Could not load file or assembly 'SourceCode.HostClientAPI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=16a2c5aaaa1b130d' or one of its dependencies. This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem. (Exception from HRESULT: 0x800736B1)]

   System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) +596

   System.Web.Configuration.CompilationSection.LoadAllAssembliesFromAppDomainBinDirectory() +211

   System.Web.Configuration.CompilationSection.LoadAssembly(AssemblyInfo ai) +46

   System.Web.Compilation.BuildManager.GetReferencedAssemblies(CompilationSection compConfig) +177

   System.Web.Compilation.WebDirectoryBatchCompiler..ctor(VirtualDirectory vdir) +267

   System.Web.Compilation.BuildManager.BatchCompileWebDirectoryInternal(VirtualDirectory vdir, Boolean ignoreErrors) +39

   System.Web.Compilation.BuildManager.BatchCompileWebDirectory(VirtualDirectory vdir, VirtualPath virtualDir, Boolean ignoreErrors) +429

   System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath) +75

   System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) +582

   System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) +93

   System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean noAssert) +111

   System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp, Boolean noAssert) +54

   System.Web.UI.PageHandlerFactory.GetHandlerHelper(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath) +31

   System.Web.UI.PageHandlerFactory.System.Web.IHttpHandlerFactory2.GetHandler(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath) +40

   System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, VirtualPath path, String pathTranslated, Boolean useAppConfig) +139

   System.Web.MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +128

   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +161


 





Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433


 


Thanks,


Aman


 

Can you verify that the SourceCode.HostClientAPI exists in the GAC? Are you running a 64Bit server?


If so you may want to load a 64bit asp.net.


C:WINDOWSmicrosoft.netFramework64v2.0.50727aspnet_regiis.exe -i), disabling running of 32 bit apps in win64 on application pools (cscript %SYSTEMDRIVE%inetpubadminscriptsadsutil.vbs SET W3SVC/AppPools/Enable32bitAppOnWin64 0)


The SourceCode.HostClientAPI dosen't exists in C:WindowsAssembly.


Both the server and developer system are running on 32 bit Windows Server 2003 OS.


Thanks,


Aman


GAC the SourceCode.HostClientAPI from your [INSTALL DIR]Host Serverin


let me know if this helps.


As mentioned in the post earlier, this is the development server and no K2 instance is installed on this machine. We hace K2 installed in other box. To make a call and update Smartobjects I am making use of the API, to access the API I have included the reference of the dll in my application.


Hope it gives a better picture, which might help you.


Thanks,


Aman


If the machine doesnt have any K2 Components you can do a K2 Client installation, that should drop all the files you will need. You can refer to the K2 Documentation:


K2 blackpearl Installation Guide > Installing K2 blackpearl > Installing a distributed environment > Installing the Client Components > Install the K2 for Visual Studio component


Vernon


Reply