Sitecore Commerce Business Tools doesn't load - sitecore

I'm facing a problem with loading the Sitecore Commerce Business Tools on my local machine. I don't get any error in my browser which you can check on the following screenshoot, but the page is not initialized:
Seems like the operations GetNavigationView() and GetLanguageView() are stuck on getting data, but I couldn't figure out what could be the problem.
As preparation steps, I did the Sitecore Commerce Bootstrap, and Environment Initialization via Postman and everything went ok.
In the CommerceAuthoring_Sc9\wwwroot\config.json I set up the certificate thumbprint and here is what I have in the AppSettings:
"AppSettings": {
...
"SitecoreIdentityServerUrl": "https://localhost:5050",
"AllowedOrigins": [
"https://localhost:4200",
"https://sxa.storefront.com"],
"AntiForgeryEnabled": false,
"UseHttpsInKestrel": true,
"SslPort": 5000,
"SslPfxPath": "wwwroot/localhost.pfx",
"SslPfxPassword": "sitecore"
}
Also in the CommerceAuthoring_Sc9\wwwroot\bootstrap\Global.json I added all the environments I use.
Here you can check some of the errors I noticed in the CommerceAuthoring logs:
ERROR ImportMinion Error Access to the path 'C:\Import.lock' is denied. Inner
...
ERROR SitecoreConnectionManager.Error: Message=Invalid URI: The hostname could not be parsed.|Trace=
at System.Uri.CreateThis(String uri, Boolean dontEscape, UriKind uriKind)
at Sitecore.Commerce.Plugin.Management.SitecoreConnectionManager.ProcessRequest(CommerceContext commerceContext, String action, String method, ItemModel itemModel) System.UriFormatException: Invalid URI: The hostname could not be parsed.
at System.Uri.CreateThis(String uri, Boolean dontEscape, UriKind uriKind)
at Sitecore.Commerce.Plugin.Management.SitecoreConnectionManager.ProcessRequest( CommerceContext commerceContext, String action, String method, ItemModel itemModel)
...
ERROR SitecoreConnectionManager.Error: Message=One or more errors occurred.|Trace= at System.Threading.Tasks.Task`1.GetResultCore(Boolean waitCompletionNotification)
at Sitecore.Commerce.Plugin.Management.SitecoreConnectionManager.ProcessRequest(CommerceContext commerceContext, String action, String method, ItemModel itemModel)
System.AggregateException: One or more errors occurred. ---> System.Threading.Tasks.TaskCanceledException: A task was canceled.
--- End of inner exception stack trace ---
at System.Threading.Tasks.Task`1.GetResultCore(Boolean waitCompletionNotification)
at Sitecore.Commerce.Plugin.Management.SitecoreConnectionManager.ProcessRequest(CommerceContext commerceContext, String action, String method, ItemModel itemModel)
---> (Inner Exception #0) System.Threading.Tasks.TaskCanceledException: A task was canceled.<---
...
ERROR Management.block.getitemsbypath: Sitecore Item Service Get item failed, Item /sitecore/Commerce/Commerce Control Panel/Commerce Engine Settings/Commerce Terms/BusinessTools/ViewNames not found.
I checked some solutions that were already mentioned across the forums but no luck fo far.
I'll very appreciate if you have any advice for me!
Updated
After some time, we got the following error on the UAT env. but I'm not sure if we can do a Commerce Bootstrap there without losing our data:
INFO Management.block.getitembypath./sitecore/Commerce/Commerce Control Panel/Storefront Settings/Storefronts/CommerceEngineDefaultStorefront|en
INFO Management.block.getitembypath./sitecore/Commerce/Commerce Control Panel/Storefront Settings/Storefronts/CommerceEngineDefaultStorefront: Language=en
ERROR SitecoreConnectionManager.Error: Message=Unexpected character encountered while parsing value: <. Path '', line 0, position 0.|Trace= at Newtonsoft.Json.JsonTextReader.ParseValue()
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.ReadForType(JsonReader reader, JsonContract contract, Boolean hasConverter)
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize(JsonReader reader, Type objectType, Boolean checkAdditionalContent)
at Newtonsoft.Json.JsonSerializer.DeserializeInternal(JsonReader reader, Type objectType)
at Newtonsoft.Json.JsonConvert.DeserializeObject(String value, Type type, JsonSerializerSettings settings)
at Newtonsoft.Json.JsonConvert.DeserializeObject[T](String value, JsonSerializerSettings settings)
at Sitecore.Commerce.Plugin.Management.SitecoreConnectionManager.GetItemByPath(CommerceContext commerceContext, String path, String language)
Newtonsoft.Json.JsonReaderException: Unexpected character encountered while parsing value: <. Path '', line 0, position 0.
at Newtonsoft.Json.JsonTextReader.ParseValue()
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.ReadForType(JsonReader reader, JsonContract contract, Boolean hasConverter)
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize(JsonReader reader, Type objectType, Boolean checkAdditionalContent)
at Newtonsoft.Json.JsonSerializer.DeserializeInternal(JsonReader reader, Type objectType)
at Newtonsoft.Json.JsonConvert.DeserializeObject(String value, Type type, JsonSerializerSettings settings)
at Newtonsoft.Json.JsonConvert.DeserializeObject[T](String value, JsonSerializerSettings settings)
at Sitecore.Commerce.Plugin.Management.SitecoreConnectionManager.GetItemByPath(CommerceContext commerceContext, String path, String language)
ERROR Management.block.getitembypath: Sitecore Item Service Get item failed, Item /sitecore/Commerce/Commerce Control Panel/Storefront Settings/Storefronts/CommerceEngineDefaultStorefront not found.
ERROR CtxMsg.Error.InvalidShop: Text=Shop 'CommerceEngineDefaultStorefront' does not exist.
ERROR PipelineAbort:Shop 'CommerceEngineDefaultStorefront' does not exist.
ERROR CtxMsg.Error.InvalidShop: Text=Shop 'CommerceEngineDefaultStorefront' does not exist.
ERROR CommerceController.OnActionExecuting.BadRequest: Code=Error|TermKey=InvalidShop|Text=Shop 'CommerceEngineDefaultStorefront' does not exist.
Also, the storefront item 'CommerceEngineDefaultStorefront' exist in the database that is specified in the PlugIn.Content.PolicySet-1.0.0.json file. I feel some of the json files has invalid params/values or the formatting is wrong, but I couldn't find any lead, furthermore, they haven't been changed recently.
Answer
Eventualy, it appeared the our CD was down for some period.

Related

You called the function 'Value Selector' with these arguments

I am in the process of implementing a LoanBroker with Mulesoft but have an error message when sending a request. I get the following error message back from Postman and Mulesoft Anypoint Studio:
ERROR 2021-06-27 15:20:51,133 [[MuleRuntime].uber.04: [loanbroker].LoanBrokerFlow_Gr7.CPU_LITE #254be3ee] [processor: LoanBrokerFlow_Gr7/processors/0; event: 7e49f560-d74a-11eb-b598-b66921dc5aa5] org.mule.runtime.core.internal.exception.OnErrorPropagateHandler:
********************************************************************************
Message: "You called the function 'Value Selector' with these arguments:
1: Binary ("" as Binary {base: "64"})
2: Name ("amount")
But it expects one of these combinations:
(Array, Name)
(Array, String)
(Date, Name)
(DateTime, Name)
(LocalDateTime, Name)
(LocalTime, Name)
(Object, Name)
(Object, String)
(Period, Name)
(Time, Name)
1| payload.amount
^^^^^^^^^^^^^^
Trace:
at main (line: 1, column: 1)" evaluating expression: "payload.amount".
Element : LoanBrokerFlow_Gr7/processors/0 # loanbroker:bi_gruppe7.xml:34 (Copy_of_setAmount)
Element DSL : <set-variable value="#[payload.amount]" doc:name="Copy_of_setAmount" doc:id="cbcca557-1a69-4cf2-80b1-64333175589d" variableName="amount"></set-variable>
Error type : MULE:EXPRESSION
FlowStack : at LoanBrokerFlow_Gr7(LoanBrokerFlow_Gr7/processors/0 # loanbroker:bi_gruppe7.xml:34 (Copy_of_setAmount))
(set debug level logging or '-Dmule.verbose.exceptions=true' for everything)
********************************************************************************
Can anyone help me?
Thanks
This generally happens when one tries to access inner value of a payload like json but incoming payload is NOT actually a json type.
One could check the payload mediaType and then try to access the amount in order to avoid Value Selector exception.
%dw 2.0
output application/java
---
if( !isEmpty(payload) and payload.^mediaType contains "json" )
payload.amount
else
read(payload, "application/json").amount //best effort
Would recommend creating a separate dataweave file like dwl/set-amount.dwl and referencing it.
You are probably sending some body in the HTTP request from Postman but Mule doesn't know how to read it. Maybe you did not the Content-Type header in the request to let DataWeave know it is a JSON (application/json) or XML (application/XML).
Ensure you are sending the right content type.
I ran into the same situation. I know exactly the base64 is a json. So, I tried to set the MIME Type by
<set-payload value="#[payload]" doc:name="Set Payload" mimeType="application/json"/>
It works for me.

Sitecore: Value cannot be null. Parameter name: uri

Exception: System.ArgumentNullException
Message: Value cannot be null.
Parameter name: uri
Source: Sitecore.Kernel
I was editing a placeholder item in a local
Sitecore 8.1 (rev. 151207) instance when I got this error. Now I can't edit, delete, or reset it (or its parent folders). I also can't read the item in the content editor as the error pops up when I click on the parent folder. I've tried deleting/editing it and it's parent folder from the content editor, through code, and through PowerShell commands but the same error always shows.
I've also tried replacing my configs and bin folders with my backup copies, clearing cache, restarting IIS and the app pool, but nothing has helped.
I'm completely stuck. Does anyone know how to fix this?
Edit:
The full error in the logs is:
Exception: System.ArgumentNullException
Message: Value cannot be null.
Parameter name: uri
Source: Sitecore.Kernel
at Sitecore.Diagnostics.Assert.ArgumentNotNull(Object argument, String argumentName)
at Sitecore.Data.ItemUri..ctor(ItemUri uri)
at Sitecore.Data.Items.Item.GetItemUriFromSourceItem()
at Sitecore.Data.Items.Item.get_SourceUri()
at Sitecore.Data.Items.Item.get_Source()
at Sitecore.Data.Fields.Field.GetSourceItem()
at Sitecore.Data.Fields.Field.GetInheritedValue(Boolean allowStandardValue)
at Sitecore.Pipelines.GetFieldValue.GetInheritedValue.Process(GetFieldValueArgs args)
at (Object , Object[] )
at Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args)
at Sitecore.Data.Fields.Field.GetValue(Boolean allowStandardValue, Boolean allowDefaultValue, Boolean allowFallbackValue, Boolean allowInheritValue, Boolean allowInnerValue)
at Sitecore.Pipelines.ItemProvider.GetItem.GetLanguageFallbackItem.IsItemFallbackEnabled(Item item)
at Sitecore.Pipelines.ItemProvider.GetItem.GetLanguageFallbackItem.Process(GetItemArgs args)
at (Object , Object[] )
at Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args)
at Sitecore.Data.Managers.PipelineBasedItemProvider.ExecuteAndReturnResult[TArgs,TResult](String pipelineName, String pipelineDomain, Func`1 pipelineArgsCreator, Func`1 fallbackResult)
at Sitecore.Data.Managers.ItemManager.GetItem(ID itemId, Language language, Version version, Database database, SecurityCheck securityCheck)
at Sitecore.Nexus.Data.DataCommands.GetChildrenCommand.Execute(Item )
at Sitecore.Data.Engines.EngineCommand`2.Execute()
at Sitecore.Data.Managers.ItemProvider.GetChildren(Item item, ChildListOptions options)
at Sitecore.Data.Managers.ItemProvider.GetChildren(Item item, SecurityCheck securityCheck, ChildListOptions options)
at Sitecore.Data.Managers.PipelineBasedItemProvider.ExecuteAndReturnResult[TArgs,TResult](String pipelineName, String pipelineDomain, Func`1 pipelineArgsCreator, Func`1 fallbackResult)
at Sitecore.Data.Managers.PipelineBasedItemProvider.GetChildren(Item item, SecurityCheck securityCheck)
at Sitecore.Collections.ChildList.Populate(ChildListOptions options)
at Sitecore.Shell.Framework.Pipelines.DeleteItems.GetItemClones(Item item, Boolean processChildren)
at Sitecore.Shell.Framework.Pipelines.DeleteItems.GetItemClones(Item item, Boolean processChildren)
at Sitecore.Shell.Framework.Pipelines.DeleteItems.GetItemClones(List`1 items)
at Sitecore.Shell.Framework.Pipelines.DeleteItems.GetCheckCloneLinksMessage(List`1 items)
at Sitecore.Shell.Framework.Pipelines.DeleteItems.CheckCloneLinks(ClientPipelineArgs args)
The exception you provided occurs because you have nonempty invalid value in the __Source Item - {19B597D3-2EDD-4AE2-AEFE-4A94C7F10E31} field in your item. __Source Item is responsible for storing the original item URI for the clone items.
I don't know how you achieved that because there is a processor ValidateCloneSourceModifications in the saveItem pipeline that prevents of saving items with invalid __Source Item field.
I was able to reproduce your exception by changing the field value in the DB.
How to fix:
Find you broken field in the master DB -> SharedFields table. The FieldId is '19B597D3-2EDD-4AE2-AEFE-4A94C7F10E31'.
Fix it. It should be something like sitecore://master/{AE76A034-9491-4B83-99F5-39F227D6FB59}, where the ID is the original item id. You could also just set '' as a value, but it will remove the binding to the original item.
Clear cache.
It must help.
You can try the DB Browser /sitecore/admin/dbbrowser.aspx with this tool you can also delete items.
If this DB Browser admin tools fail, then I'm curious what's in the master database, check directly in sql what make this item special is than an option.

Sitecore 8: Getting application error when removing broken links

I try to remove broken links on my master database using the tool provided by the following url.
http://mysite/sitecore/admin/RemoveBrokenLinks.aspx
After some time the process being interrupted and I got the following error on Sitecore log.
6220 10:56:26 INFO Removing broken link- Database: master, Item: /sitecore/content/Home/blog/2012/January/13/totaljobs-group-benefit-from-expert-sitecore-consultancy-delivered-by-codehouse, Field: __Renderings, Target item database: master, Target item path: /sitecore/content/global/Codehouse Widgets/Mini Form Widgets/newsletter-subscription
6220 10:56:26 INFO Done
6220 10:56:26 INFO Removing broken link- Database: master, Item: /sitecore/content/Home/blog/2012/January/13/totaljobs-group-benefit-from-expert-sitecore-consultancy-delivered-by-codehouse, Field: __Renderings, Target item database: master, Target item path: /sitecore/content/global/Codehouse Widgets/Mini Form Widgets/sitecore-demo-text-only
6220 10:56:26 INFO Done
6220 10:56:26 ERROR Error looking up template field. Field id: {00000000-0000-0000-0000-000000000000}. Template id: {0437FEE2-44C9-46A6-ABE9-28858D9FEE8C}
Exception: System.ArgumentOutOfRangeException
Message: Null ID is not allowed.
Parameter name: fieldID.
Actual value was {00000000-0000-0000-0000-000000000000}.
Source: Sitecore.Kernel
at Sitecore.Data.Templates.TemplateSection.GetField(ID fieldID)
at Sitecore.Data.Templates.Template.DoGetField(ID fieldID, String fieldName, Stack`1 stack)
at Sitecore.Data.Templates.Template.DoGetField(ID fieldID, String fieldName, Stack`1 stack)
at Sitecore.Data.Templates.Template.DoGetField(ID fieldID, String fieldName, Stack`1 stack)
at Sitecore.Data.Templates.Template.GetField(ID fieldID)
6220 10:56:26 ERROR Application error.
Exception: System.Web.HttpUnhandledException
Message: Exception of type 'System.Web.HttpUnhandledException' was thrown.
Source: System.Web
at System.Web.UI.Page.HandleError(Exception e)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest()
at System.Web.UI.Page.ProcessRequest(HttpContext context)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
Nested Exception
Exception: System.ArgumentOutOfRangeException
Message: Null ID is not allowed.
Parameter name: fieldID.
Actual value was {00000000-0000-0000-0000-000000000000}.
Source: Sitecore.Kernel
at Sitecore.Data.Templates.TemplateSection.GetField(ID fieldID)
at Sitecore.Data.Templates.Template.DoGetField(ID fieldID, String fieldName, Stack`1 stack)
at Sitecore.Data.Templates.Template.DoGetField(ID fieldID, String fieldName, Stack`1 stack)
at Sitecore.Data.Templates.Template.DoGetField(ID fieldID, String fieldName, Stack`1 stack)
at Sitecore.Data.Templates.Template.GetField(ID fieldID)
at Sitecore.Data.Fields.Field.GetTemplateField()
at Sitecore.Data.Fields.FieldTypeManager.GetField(Field field, String runtimeValue)
at Sitecore.sitecore.admin.RemoveBrokenLinks.FixBrokenLinksInDatabase(Database database, Boolean serializeItem)
at Sitecore.sitecore.admin.RemoveBrokenLinks.FixBrokenLinksOnClick(Object sender, EventArgs e)
at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
Can you made a cleanup database before doing RemoveBrokenLinks?
Tu clean up database go to ->Control Panel->Database->Clean up Database
I guess you have some orphaned items (items without templates)
When you are doing a Cleanup Database next tasks are executed:
Removes items that have parents, but the parents are not in the item
tree.
Removes invalid language data.
Removes fields for non existing items.
Removes orphaned items.
Removes unused blob records.
Removes fields from orphaned items removed in step 4.
Rebuilds the Descendants table (which stores parent/child relationships).
Clears all caches.
It's quite odd that it didn't resolve the issue by using Clean up Database or by Rebuilding the link database.
Few questions:
During the clean up and rebuilding process, did you find any
relevant entry related to the issue in your Sitecore log? If yes, could you please paste it here, as well.
Reading the stack traces you provided, it looks like that there is/are orphaned template(s) and that's the reason why it throws an Exception: System.ArgumentOutOfRangeException. Could you please repeat the same rebuild and clean up process, and let us know the result of the 2nd run?
Alternatively, if you find repeating the process a very time consuming and performance heavy then you might want to consider creating a LinkDatabaseRefreshTool.aspx file, put it inside the \Website\admin folder with the following code as your processor:
foreach (var specificItem in itemList)
{
specificItem.Editing.BeginEdit();
Sitecore.Globals.LinkDatabase.UpdateReferences(specificItem);
specificItem.Editing.EndEdit();
}
Create an asp:Textbox and a submit button that invokes this method OnClick. Open the tool by accessing the http:\\YOUR_WEBSITE\admin\LinkDatabaseRefreshTool.aspx
I experienced the same issue before, and I just rebuild it again and that resolved the issue. Maybe just the same solution on your end, still worth a try.

Sitecore WFFM Save To Database failed

I get the following error in the Sitecore log file. On the Save To Database action in a WFFM form. Web Forms for Marketers 2.4 rev. 141008.
I have a custom WFMDataProvider that just return a connectionString. I get the error on production CD and not on CMS. (i'm not using the remoteWfmService) What am I missing?
3292 09:42:32 ERROR Save To Database failed.
Exception: System.Reflection.ReflectionTypeLoadException
Message: Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
Source: mscorlib
at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
at System.Reflection.RuntimeModule.GetTypes()
at System.Reflection.Assembly.GetTypes()
at System.Data.Metadata.Edm.ObjectItemAttributeAssemblyLoader.LoadTypesFromAssembly()
at System.Data.Metadata.Edm.ObjectItemAssemblyLoader.Load()
at System.Data.Metadata.Edm.AssemblyCache.LoadAssembly(Assembly assembly, Boolean loadReferencedAssemblies, ObjectItemLoadingSessionData loadingData)
at System.Data.Metadata.Edm.AssemblyCache.LoadAssembly(Assembly assembly, Boolean loadReferencedAssemblies, KnownAssembliesSet knownAssemblies, EdmItemCollection edmItemCollection, Action`1 logLoadMessage, Object& loaderCookie, Dictionary`2& typesInLoading, List`1& errors)
at System.Data.Metadata.Edm.ObjectItemCollection.LoadTypesExpensiveWay(Assembly assembly)
at System.Data.Objects.DataClasses.RelationshipManager.TryGetRelationshipType(IEntityWrapper wrappedOwner, Type entityClrType, String relationshipName, AssociationType& associationType)
at System.Data.Objects.DataClasses.RelationshipManager.GetRelatedEndInternal(String relationshipName, String targetRoleName)
at System.Data.Objects.DataClasses.RelationshipManager.GetRelatedReference[TTargetEntity](String relationshipName, String targetRoleName)
at Sitecore.Forms.Data.Field..ctor(IField field, Form form)
at Sitecore.Forms.Data.DataProviders.WFMDataProvider.<>c__DisplayClass7.<InsertForm>b__6(IField f)
at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext()
at Sitecore.Forms.Data.DataProviders.WFMDataProvider.InsertForm(IForm form)
at Sitecore.Forms.Data.DataManager.InsertForm(ID formId, AdaptedResultList fields, ID sessionID, String data)
at Sitecore.Form.Submit.SaveToDatabase.Execute(ID formid, AdaptedResultList fields, Object[] data)
3292 09:42:32 WARN Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
Exception: System.Reflection.ReflectionTypeLoadException
Message: Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
Source: mscorlib
at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
at System.Reflection.RuntimeModule.GetTypes()
at System.Reflection.Assembly.GetTypes()
at System.Data.Metadata.Edm.ObjectItemAttributeAssemblyLoader.LoadTypesFromAssembly()
at System.Data.Metadata.Edm.ObjectItemAssemblyLoader.Load()
at System.Data.Metadata.Edm.AssemblyCache.LoadAssembly(Assembly assembly, Boolean loadReferencedAssemblies, ObjectItemLoadingSessionData loadingData)
at System.Data.Metadata.Edm.AssemblyCache.LoadAssembly(Assembly assembly, Boolean loadReferencedAssemblies, KnownAssembliesSet knownAssemblies, EdmItemCollection edmItemCollection, Action`1 logLoadMessage, Object& loaderCookie, Dictionary`2& typesInLoading, List`1& errors)
at System.Data.Metadata.Edm.ObjectItemCollection.LoadTypesExpensiveWay(Assembly assembly)
at System.Data.Objects.DataClasses.RelationshipManager.TryGetRelationshipType(IEntityWrapper wrappedOwner, Type entityClrType, String relationshipName, AssociationType& associationType)
at System.Data.Objects.DataClasses.RelationshipManager.GetRelatedEndInternal(String relationshipName, String targetRoleName)
at System.Data.Objects.DataClasses.RelationshipManager.GetRelatedReference[TTargetEntity](String relationshipName, String targetRoleName)
at Sitecore.Forms.Data.Field..ctor(IField field, Form form)
at Sitecore.Forms.Data.DataProviders.WFMDataProvider.<>c__DisplayClass7.<InsertForm>b__6(IField f)
at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext()
at Sitecore.Forms.Data.DataProviders.WFMDataProvider.InsertForm(IForm form)
at Sitecore.Forms.Data.DataManager.InsertForm(ID formId, AdaptedResultList fields, ID sessionID, String data)
at Sitecore.Form.Submit.SaveToDatabase.Execute(ID formid, AdaptedResultList fields, Object[] data)
at Sitecore.Form.Core.Submit.SubmitActionManager.ExecuteSaving(ID formID, ControlResult[] list, ActionDefinition[] actions, Boolean simpleAdapt, ID sessionID)
3292 09:42:32 WARN Web Forms for Marketers: an exception: Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information. has occured while trying to execute an action.
I have found that the MSCaptcha.dll is not deployed. Normally you get a Exception when this file is missing. But in this case the App_Config\include\Captcha.config was also missing.
If you remove this 2 files it looks like everything works fine with a form (without captcha) but the save to database action does not work and needs this MSCaptcha.dll. And so gives the error mentioned in the question.
I am almost certain that this is the issue. I only need a deploy to confirm.

SharePoint SoapServerException calling GetListItems web service

I have the following statement in my code:
System.Xml.XmlNode items = lstWebs.GetListItems(
"Tasks", string.Empty, listQuery, listViewFields,
string.Empty, listQueryOptions, WorkspaceId);
When executing this, the following exception occurs:
Exception of type 'Microsoft.SharePoint.SoapServer.SoapServerException' was thrown.
Exception Source is:
System.Web.Services
Stack Trace:
at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
at ImpersonationConsoleApp.MossLists.Lists.GetListItems(String listName, String viewName, XmlNode query, XmlNode viewFields, String rowLimit, XmlNode queryOptions, String webID) in C:\Documents and Settings\david\My Documents\_Dew02SiteCreator\DeWProjectStarter\ImpersonationConsoleApp\Web References\MossLists\Reference.cs:line 435
at ImpersonationConsoleApp.Program.DeleteTasksIfNotExist(DataRow[] drTasksdel, String siteURL) in C:\Documents and Settings\david\My Documents\_Dew02SiteCreator\DeWProjectStarter\ImpersonationConsoleApp\Program.cs:line 1384
I have confirmed the site URL and it is fine.
Could you please help on why the exception is occurring? Do I need to reset IIS?
please find the detail.
SoapException.InnerException is Null.
However the soapExcetion.Detail.InnerText is showing: The system cannot find the file specified. (Exception from HRESULT: 0x80070002)
Is the name tasks also the actual listname in the url? i.e. http://siteurl/lists/tasks? is the list in a subsite and are you using the service under the site-collection?
IF the list is in a subsite the use http://sitecollectionurl/subsite/_vti_bin/lists.asmx as the Service url, otherwise the lists.asmx will try to find the tasks list in the rootweb instead of the subsite.
The signature for GetListItems is
GetListItems(ListID, "", queryNode, viewFieldsNode, Nothing, queryOptionsNode, Nothing)
Try simplifying queryNode, viewFieldsNode and queryOptionsNode to the minimal.
In VB.NET
Dim caml = New XmlDocument
Dim queryNode = caml.CreateElement("Query")
Dim viewFieldsNode = caml.CreateElement("ViewFields")
Dim queryOptionsNode = caml.CreateElement("QueryOptions")
queryOptionsNode.InnerXml = "<ViewAttributes Scope=""Recursive"" /><IncludeMandatoryColumns>FALSE</IncludeMandatoryColumns>"
In C#
var caml = new XmlDocument();
var queryNode = caml.CreateElement("Query");
var viewFieldsNode = caml.CreateElement("ViewFields");
var queryOptionsNode = caml.CreateElement("QueryOptions");
queryOptionsNode.InnerXml = "<ViewAttributes Scope=\"Recursive\" /><IncludeMandatoryColumns>FALSE</IncludeMandatoryColumns>";
If it works, then the web service setup is correct.
When I had the mentioned problem, it was my invalid XML that caused it. There is a missing 'type' attribute on the 'Value' element of the 'Where' element in queryNode. I found it here from Microsoft.
Type | Required Text. Specifies the data type for the value contained by this element.
It works after adding the Type attribute. Check if any missing requirements for the xml in one of the nodes mentioned above?
Have you tried running with elevated permissions, it looks like the running user does not hav sufficient privileges to query the data...
SPSecurity.RunWithElevatedPrivileges