Generated form has an error: Could not load the assembly...

  • 6 January 2009
  • 9 replies
  • 5 views

Badge +2

Hi!

I was trying a very simple workflow from a training material module. It is an approve/decline workflow which should display the employee and his expenses on a generated form, but the only thing i get is an error page. I tried the complete tutorial already a second time, but i got the same error.

Can anyone help?

Here is the complete error:

Server Error in '/Workspace/ClientEventPages' Application.
--------------------------------------------------------------------------------

Parser Error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

Parser Error Message: Could not load the assembly 'fwExpenseReport'. Make sure that it is compiled before accessing the page.

Source Error:


Line 1:  <%@ page language="C#" autoeventwireup="true" inherits="SourceCode.Workflow.FormsGeneration.fwApprovalForm, fwExpenseReport" %>
Line 2:  <%@ Register Assembly="SourceCode.SharePoint.Workflow.WebControls, Version=4.0.0.0, Culture=neutral, PublicKeyToken=16a2c5aaaa1b130d" Namespace="SourceCode.SharePoint.Workflow.WebControls" TagPrefix="cc1" %>
Line 3:  
 

Source File: /Workspace/ClientEventPages/fwExpenseReport/fwApprovalForm.aspx    Line: 1


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


9 replies

Badge +4

Launch IIS manager and check what is deployed under /Workspace/ClientEventPages/

I would also try a re-deploy and check for errors there.

Badge +2

Hi Jey, thanks for your help!

I made some progress in the meantime and tried what you just had written. the form is there and the dll file is also there. I googled the error and tried to create an asp.net application in the folder. This "works" but replaces the error only with another error: i have created an empty form with only two actions and in this case i can see the form now, but the actions are missing.

the other form which should also display a user and his expenses shows only the error message quoted below.

I think it is not correct to create the asp.net application on my own! Also I am working on an official K2 vpc image so I cannot imagine any configuration mistakes.

Jey, do you have asp.net applications below the ClientEventPages-Folder?

 ReBuild+Deploy is always successful and doesn't change anything :(

 

Full Error:

Server Error in '/Workspace/ClientEventPages/fwExpenseReport' Application.
--------------------------------------------------------------------------------

Authentication required for session 33D21A3989A04D017C62838F9C280707
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.Exception: Authentication required for session 33D21A3989A04D017C62838F9C280707

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:


[Exception: Authentication required for session 33D21A3989A04D017C62838F9C280707]
   SourceCode.SmartObjects.Client.SmartObjectClientServer.GetServerInfo() +298
   SourceCode.SmartObjects.Client.SmartObjectClientServer.GetServerVersion() +6
   SourceCode.SmartObjects.Client.SmartObjectClientServer.GetSmartObject(String name) +15
   SourceCode.Data.Common.SOUtils.GetSmartObject(SOConnection connection, String objectName) +417
   SourceCode.Data.Common.ExecParser.RunSmartObject(String ObjectName, String MethodName) +118
   SourceCode.Data.Common.ExecParser.Parse() +1995
   SourceCode.Data.Common.ExecParser.get_Data() +51
   SourceCode.Data.Common.QueryParser.DoExec() +71
   SourceCode.Data.Common.QueryParser.DoQuery() +344
   SourceCode.Data.Common.QueryParser.get_Data() +60
   SourceCode.Data.SmartObjectsClient.SODataReader.Initialize() +108
   SourceCode.Data.SmartObjectsClient.SODataReader..ctor(SOCommand command, CommandBehavior cmdBehaviour) +54
   SourceCode.Data.SmartObjectsClient.SOCommand.ExecuteDbDataReader(CommandBehavior behavior) +44
   SourceCode.Data.SmartObjectsClient.SOCommand.ExecuteReader(CommandBehavior behavior) +33
   SourceCode.Data.SmartObjectsClient.SODataAdapter.FillInternal(DataSet dataSet, DataTable[] dataTables, Int32 startRecord, Int32 maxRecords, String srcTable, SOCommand command, CommandBehavior behavior) +77
   SourceCode.Data.SmartObjectsClient.SODataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +132
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String srcTable) +83
   System.Web.UI.WebControls.SqlDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments) +1770
   System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +17
   System.Web.UI.WebControls.DataBoundControl.PerformSelect() +149
   System.Web.UI.WebControls.BaseDataBoundControl.DataBind() +70
   System.Web.UI.WebControls.FormView.DataBind() +4
   System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound() +82
   System.Web.UI.WebControls.FormView.EnsureDataBound() +163
   System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls() +69
   System.Web.UI.Control.EnsureChildControls() +87
   System.Web.UI.Control.PreRenderRecursiveInternal() +50
   System.Web.UI.Control.PreRenderRecursiveInternal() +170
   System.Web.UI.Control.PreRenderRecursiveInternal() +170
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2041

 


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

Badge +3
At first look, it seems like you just need to turn off anonymous access in IIS so that the web request is authenticated
Badge +2

Hi panmanphil,

based on the posted error message, I had the same idea, but the ClientEventPages-App has only integrated authentication enabled and in the case of creating my own asp.net-app it inherits this setting. Do you have another idea?

Badge +2

Hi again!

I resetted the complete vpc and created the simplest possible workflow containing a single form with two options (XXX or ZZZ). But i still get the error quoted in my first post.

I zipped and attached the project to this post so maybe someone can check whether I missed an important step. My vpc image is "Denallix V2", if someone is familiar with it, this information maybe helps.

 Thanks everyone :-(

Badge +2

ok I somewhat solved the problem on my own:

first: you need to create an asp.net application on your subfolder in the directory "default website/workspace/clienteventpages/<myWorkflowProcess>"

and second: Select the K2 application pool instead of the default application pool (this solves the security-context-error) for this new asp.net-app

Though I did an redeploy of the workflow and some restarts after the first step in the process of my error search, I think they weren't neccessary, so if you experience the same problem and the two steps above aren't enough, then try redeploy and restart.

Thanks everyone for your help!

Badge +4

What  worked for me was adding the following assemblies from the server where sharepoint was installed:


Microsoft.Sharepoint.dll


Microsoft.sharepoint.workflowactions.dll


Microsoft.Sharepoint.Search.dll


I grabbed from C:Program FilesCommon FilesMicrosoft Sharedweb server extensions12ISAPI  on the Sharepoint Server


and added them to 


C:Windowsassembly on the  server were K2 is installed.

Badge

Hi,


Is it required to copy the DLLs if I have both K2 and SharePoint 2010 installed in one box ?


-Samarendra Swain


Team SharePoint


Mahindra Satyam

Badge

encountered the same error and followed your resolution. the problem was resolved :)


thank you for sharing, Fabse.

Reply