Skip to main content
I received the following error when moving changes to my asp.net application which uses the K2ROM up to our development server (the server is both our web server and K2 server for development).


Parser Error Message: Access is denied: 'K2ROM'.

Source Error:


Line 329: type="Microsoft.VJSharp.VJSharpCodeProvider, VJSharpCodeProvider, Version=7.0.5000.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" /></compilers>
Line 330: <assemblies>
Line 331:<!--
Line 332:BEGIN section inserted by Device Update 4 installer.
Line 333:-->


Source File: c:windowsmicrosoft.netframeworkv1.1.4322Configmachine.config Line: 331

Assembly Load Trace: The following information can be helpful to determine why the assembly 'K2ROM' could not be loaded.


=== Pre-bind state information ===
LOG: DisplayName = K2ROM
(Partial)
LOG: Appbase = file:///D:/DEVPORTAL
LOG: Initial PrivatePath = bin
Calling assembly : (Unknown).
===

LOG: Policy not being applied to reference at this time (private, custom, partial, or location-based assembly bind).
LOG: Post-policy reference: K2ROM
LOG: Attempting download of new URL file:///C:/WINDOWS/Microsoft.NET/Framework/v1.1.4322/Temporary ASP.NET Files/root/cebadb01/8b84375c/K2ROM.DLL.
LOG: Attempting download of new URL file:///C:/WINDOWS/Microsoft.NET/Framework/v1.1.4322/Temporary ASP.NET Files/root/cebadb01/8b84375c/K2ROM/K2ROM.DLL.
LOG: Attempting download of new URL file:///D:/DEVPORTAL/bin/K2ROM.DLL.
LOG: Publisher policy file is not found.
LOG: No redirect found in host configuration file (C:WINDOWSMicrosoft.NETFrameworkv1.1.4322aspnet.config).
LOG: Using machine configuration file from C:WINDOWSMicrosoft.NETFrameworkv1.1.4322configmachine.config.
LOG: Post-policy reference: K2ROM, Version=3.13603.1.0, Culture=neutral, PublicKeyToken=10ba86d4fd9ffdf3




I have seen posts where other users have experienced the same issue, and usually the problem was that the proper permissions were not set on the temporary asp.net files directory on the web server. However, we have read/write permissions granted for authenticated users on the proper directories as stated in the K2 installation instructions.

The flow of events was: I made cosmetic changes to an application that references the K2ROM at certain points for workflow. I moved the files to our dev server, and begain to receive the error. The error basically shut down all of IIS for the development web server. Tried re-copying the K2ROM.dll, which had no effect. We then deleted the file, and were able to access the web server and all it's applications, including the one which (apparently) caused the problem, except of course the pages that were actually referencing K2ROM (missing assembly error as expected). We again added K2ROM.dll, and received the first error again. Finally, we restarted the web server, and everything is fine now.

The only thing in my code that changed regarding the K2ROM was that I added a new page to my application which included a user control that references the K2 ROM (I have created my own worklist control). Everything is working fine, we just experienced this error once, and I cannot reproduce it.

Any ideas on what may have caused this and how we can prevent it in the future?
I'm also getting this error but it's slightly different:

Exception Details: System.IO.FileLoadException: Access is denied: 'K2ROM'.

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.

Assembly Load Trace: The following information can be helpful to determine why the assembly 'K2ROM' could not be loaded.


=== Pre-bind state information ===
LOG: DisplayName = K2ROM, Version=3.13603.1.0, Culture=neutral, PublicKeyToken=10ba86d4fd9ffdf3
(Fully-specified)
LOG: Appbase = file:///c:/inetpub/wwwroot/K2Test
LOG: Initial PrivatePath = bin
Calling assembly : K2SmartForms, Version=3.6090.1.0, Culture=neutral, PublicKeyToken=null.
===

LOG: Attempting download of new URL file:///C:/WINDOWS/Microsoft.NET/Framework/v1.1.4322/Temporary ASP.NET Files/k2test/3d9b96b1/7fb42f07/K2ROM.DLL.
LOG: Attempting download of new URL file:///C:/WINDOWS/Microsoft.NET/Framework/v1.1.4322/Temporary ASP.NET Files/k2test/3d9b96b1/7fb42f07/K2ROM/K2ROM.DLL.
LOG: Attempting download of new URL file:///c:/inetpub/wwwroot/K2Test/bin/K2ROM.DLL.



Stack Trace:


[FileLoadException: Access is denied: 'K2ROM'.]
SourceCode.K2SmartForms.K2SmartForm.LoadData() +0
SourceCode.K2SmartForms.K2SmartForm.Page_Load(Object sender, EventArgs e) +330
System.EventHandler.Invoke(Object sender, EventArgs e) +0
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +35
System.Web.UI.Page.ProcessRequestMain() +750
The temporary aspnet folders is in the version of the framework - is it possible that the folder that you gave authenticated users permissions on was in 1.1 but your app is running on 2.0?

Reply