Invoke Workflow File:Missing key value on 'Dictionary' Object

Hi all, i am facing issues invoking workflow. The bot works fine when running in the project folder but unable to invoke due to missing key value on dictionary object.

Please assist.

image

@marct

click on import arguments and try to relink them properly

cheers

1 Like

If you are trying to fetch some value from dictionary by passig the key, check if its present in the given dictionary variable. Also check for improting or mapping it properly

Still unable to work.

This is the exception details.

RemoteException wrapping System.Xaml.XamlObjectWriterException: Missing key value on ‘Dictionary’ object.
at System.Xaml.XamlObjectWriter.GetKeyFromInstance(Object instance,
XamlType instanceType,
IAddLineInfo lineInfo)
at System.Xaml.XamlObjectWriter.Logic_DoAssignmentToParentCollection(ObjectWriterContext ctx)
at System.Xaml.XamlObjectWriter.Logic_DoAssignmentToParentProperty(ObjectWriterContext ctx)
at System.Xaml.XamlObjectWriter.WriteEndObject()
at System.Xaml.XamlWriter.WriteNode(XamlReader reader)
at System.Xaml.XamlServices.Transform(XamlReader xamlReader,
XamlWriter xamlWriter,
Boolean closeWriter)
at System.Activities.XamlIntegration.FuncFactory1.Evaluate() at System.Activities.DynamicActivity.OnInternalCacheMetadata(Boolean createEmptyBindings) at System.Activities.Activity.InternalCacheMetadata(Boolean createEmptyBindings, IList1& validationErrors)
at System.Activities.ActivityUtilities.ProcessActivity(ChildActivity childActivity,
ChildActivity& nextActivity,
Stack1& activitiesRemaining, ActivityCallStack parentChain, IList1& validationErrors,
ProcessActivityTreeOptions options,
ProcessActivityCallback callback)
at System.Activities.ActivityUtilities.ProcessActivityTreeCore(ChildActivity currentActivity,
ActivityCallStack parentChain,
ProcessActivityTreeOptions options,
ProcessActivityCallback callback,
IList1& validationErrors) at System.Activities.ActivityUtilities.CacheRootMetadata(Activity activity, LocationReferenceEnvironment hostEnvironment, ProcessActivityTreeOptions options, ProcessActivityCallback callback, IList1& validationErrors)
at System.Activities.WorkflowInspectionServices.d__3.MoveNext()
at System.Linq.Enumerable.d__172.MoveNext() at System.Linq.Enumerable.<ConcatIterator>d__591.MoveNext()
at System.Linq.Enumerable.d__172.MoveNext() at System.Linq.Enumerable.WhereSelectEnumerableIterator2.MoveNext()
at System.Linq.Enumerable.d__641.MoveNext() at System.Linq.Buffer1..ctor(IEnumerable1 source) at System.Linq.Enumerable.ToArray[TSource](IEnumerable1 source)
at UiPath.Executor.Tracking.TrackingHelpers.GetVariableNames(Activity activity)
at UiPath.Executor.Tracking.TrackingHelpers.TrackVariables(TrackingProfile profile,
WorkflowInfo workflowInfo)
at UiPath.Executor.Tracking.DebugTrackingParticipant.RegisterWorkflow(WorkflowInfo workflowInfo)
at UiPath.Executor.DebuggerPlugin.UiPath.Executor.IDebuggerPlugin.RegisterWorkflowTracking(WorkflowInfo workflowInfo)
at UiPath.Executor.Tracking.WorkflowTracking.RegisterWorkflowTracking(WorkflowInfo workflowInfo)
at UiPath.Executor.WorkflowRuntime.RegisterWorkflow(WorkflowInfo workflowInfo)
at UiPath.Executor.InProcessRunner.<>c__DisplayClass6_0.g__StartWorkflow|1()
at UiPath.Executor.InProcessRunner.BeginExecute(AsyncCallback callback,
Object state)
at UiPath.Core.Activities.ExecutorInvokeActivity.BeginExecute(AsyncCodeActivityContext context,
AsyncCallback callback,
Object state)
at System.Activities.AsyncCodeActivity.InternalExecute(ActivityInstance instance,
ActivityExecutor executor,
BookmarkManager bookmarkManager)
at System.Activities.ActivityInstance.Execute(ActivityExecutor executor,
BookmarkManager bookmarkManager)
at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor,
BookmarkManager bookmarkManager,
Location resultLocation)

Hi, @marct

This error means a key required by the Dictionary argument is missing or not set reopen ‘Import Arguments’ in Invoke Workflow, carefully relink or set all Dictionary keys, save, then run again.. ensure no key is blank or mismatched

Hi @marct

check all dictionary variables for missing keys in the invoked workflow ensure dictionary arguments are properly initialized before invoking rebuild or reassign dictionary using assign activity to avoid xaml errors

If helpful, mark as solution. Happy automation with UiPath

@marct

this would not help in solving

please provide some screenshots of where it is failing , flow etc

cheers