Hello! I have a problem with the approvals of PO, SO, SOF, SI.
When I submit an approval request and someone attempts to approve, the following error occurs and is not approved.
Microsoft.Dynamics.Nav.Runtime.NavVariant variable not initialized I dropped the debugger to see where she stopped and stopped here at the point in red:
OBJECT Codeunit 1501 Workflow Management
LOCAL PROCEDURE ExecuteQueuedEvents@21();
VAR
WorkflowEventQueue@1001 : Record 1522;
WorkflowStepInstance@1003 : Record 1504;
WorkflowRule@1006 : Record 1524;
RecRef@1000 : RecordRef;
xRecRef@1002 : RecordRef;
Variant@1004 : Variant;
xVariant@1005 : Variant;
BEGIN
WorkflowEventQueue.SETRANGE("Session ID",SESSIONID);
IF WorkflowEventQueue.FINDSET THEN
REPEAT
WorkflowStepInstance.GET(WorkflowEventQueue."Step Record ID");
IF WorkflowStepInstance.Status = WorkflowStepInstance.Status::Processing THEN BEGIN
WorkflowRecordManagement.RestoreRecord(WorkflowEventQueue."Record Index",Variant);
WorkflowRecordManagement.RestoreRecord(WorkflowEventQueue."xRecord Index",xVariant);
RecRef.GETTABLE(Variant);
xRecRef.GETTABLE(xVariant);
WorkflowStepInstance.FindWorkflowRules(WorkflowRule);
IF EvaluateCondition(RecRef,xRecRef,WorkflowStepInstance.Argument,WorkflowRule) THEN BEGIN
ExecuteResponses(RecRef,xRecRef,WorkflowStepInstance);
WorkflowEventQueue.DELETE;
END;
END;
UNTIL WorkflowEventQueue.NEXT = 0;
END;
When a person exits and enters a new one in the system, the request is approved and there is no error.
What could be the problem, I use a standard workflow with Bulgarian localization?
*This post is locked for comments