# Class ProcessActivityChangedEventArgs OptimaJet.Workflow.Core.Runtime.ProcessActivityChangedEventArgs Provides event data for [WorkflowRuntime.OnProcessActivityChanged](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/WorkflowRuntime/) and [WorkflowRuntime.OnProcessActivityChangedAsync](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/WorkflowRuntime/). Namespace: [OptimaJet.Workflow.Core.Runtime](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/) ```csharp public class ProcessActivityChangedEventArgs ``` ## Constructors `public ProcessActivityChangedEventArgs(ProcessInstance processInstance, bool transitionalProcessWasCompleted)` Initializes a new instance of the [ProcessActivityChangedEventArgs](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/ProcessActivityChangedEventArgs/) class. ### Parameters | Name | Type | Description | | --- | --- | --- | | `processInstance` | `ProcessInstance` | The process instance whose current activity changed. | | `transitionalProcessWasCompleted` | `Boolean` | [true](https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool) if a transitional process was completed and the process will stop at the current activity. | ## Properties `public Guid ProcessId { get; }` Gets the identifier of the process whose current activity changed. `public bool IsSubprocess { get; }` Gets a value indicating whether the current activity was changed for a subprocess. `public string SchemeCode { get; }` Gets the scheme code of the process. `public ProcessInstance ProcessInstance { get; }` Gets the process instance for which the current activity was changed. `public string PreviousActivityName { get; }` Gets the name of the previous activity. `public ActivityDefinition PreviousActivity { get; }` Gets the previous activity definition if available. `public ActivityDefinition CurrentActivity { get; }` Gets the current activity. This is the activity that was final for the last executed transition. [TransitionDefinition.From](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Model/TransitionDefinition/) `public string CurrentActivityName { get; }` Gets the name of the current activity. This is the activity that was final for the last executed transition. [TransitionDefinition.From](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Model/TransitionDefinition/) `public bool StateWasChanged { get; }` Gets a value indicating whether the process state changed. `public bool TransitionalProcessWasCompleted { get; }` Gets a value indicating that a transitional process was completed and the process will stop at the current activity. `public string CurrentState { get; }` Gets the name of the current state. This is the state that was final for the last executed transition. [TransitionDefinition.From](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Model/TransitionDefinition/) `public string PreviousState { get; }` Gets the name of the previous state. This is the state that was initial for the last executed direct transition. [TransitionDefinition.From](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Model/TransitionDefinition/) `public TransitionDefinition ExecutedTransition { get; }` Gets the transition definition that was executed. [Previous ParametersSerializer](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/ParametersSerializer/) [Next ProcessHistoryItem](https://api.workflowengine.io/core/OptimaJet.Workflow.Core.Runtime/ProcessHistoryItem/)