Hi,
My client is on Dynamics CRM 2016 online. They are experiencing a very weird workflow exception and behaviour. The have couple of workflows scheduled to be run and certain interval during the day, but when these workflows are due to run they suddenly get postponed 12/30/9999. All of the scheduled workflows in the system are experiencing the same behaviour.
See Exception below, Anyone one with any idea to this behaviour?
Unhandled Exception: System.InvalidOperationException: Operation is not valid due to the current state of the object.
at Microsoft.Compiler.VisualBasic.CompilerBridge.CompileExpression(CompilerBridge* , gcroot<System::String ^>* expression, gcroot<Microsoft::Compiler::VisualBasic::CompilerContext ^>* context, gcroot<System::Type ^>* targetType, gcroot<Microsoft::Compiler::VisualBasic::CompilerResults ^>* results)
at Microsoft.Compiler.VisualBasic.HostedCompiler.CompileExpression(String expression, CompilerContext context, Type targetType)
at Microsoft.VisualBasic.Activities.VisualBasicHelper.Compile[T](LocationReferenceEnvironment environment, Boolean isLocationReference)
at Microsoft.VisualBasic.Activities.VisualBasicHelper.Compile[T](CodeActivityPublicEnvironmentAccessor publicAccessor, Boolean isLocationReference)
at Microsoft.VisualBasic.Activities.VisualBasicHelper.Compile[T](String expressionText, CodeActivityPublicEnvironmentAccessor publicAccessor, Boolean isLocationExpression)
at Microsoft.VisualBasic.Activities.VisualBasicValue`1.CacheMetadata(CodeActivityMetadata metadata)
at System.Activities.CodeActivity`1.OnInternalCacheMetadataExceptResult(Boolean createEmptyBindings)
at System.Activities.Activity`1.OnInternalCacheMetadata(Boolean createEmptyBindings)
at System.Activities.Activity.InternalCacheMetadata(Boolean createEmptyBindings, IList`1& validationErrors)
at System.Activities.ActivityUtilities.ProcessActivity(ChildActivity childActivity, ChildActivity& nextActivity, Stack`1& activitiesRemaining, ActivityCallStack parentChain, IList`1& validationErrors, ProcessActivityTreeOptions options, ProcessActivityCallback callback)
at System.Activities.ActivityUtilities.ProcessActivityTreeCore(ChildActivity currentActivity, ActivityCallStack parentChain, ProcessActivityTreeOptions options, ProcessActivityCallback callback, IList`1& validationErrors)
at System.Activities.ActivityUtilities.CacheRootMetadata(Activity activity, LocationReferenceEnvironment hostEnvironment, ProcessActivityTreeOptions options, ProcessActivityCallback callback, IList`1& validationErrors)
at System.Activities.Hosting.WorkflowInstance.ValidateWorkflow(WorkflowInstanceExtensionManager extensionManager)
at System.Activities.Hosting.WorkflowInstance.RegisterExtensionManager(WorkflowInstanceExtensionManager extensionManager)
at System.Activities.WorkflowApplication.SetPersistenceManager(PersistenceManager newManager)
at System.Activities.WorkflowApplication.CreatePersistenceManager()
at System.Activities.WorkflowApplication.Load(Guid instanceId, TimeSpan timeout)
at System.Activities.WorkflowApplication.Load(Guid instanceId)
at Microsoft.Crm.Workflow.ActivityHost.StartWorkflowExecution(Activity workflow, ICommonWorkflowContext context)
at Microsoft.Crm.Workflow.ActivityHostBase.StartWorkflow(ICommonWorkflowContext context, Activity preLoadedActivity)