05-14-2024 09:14 AM
I am trying to get the Journal Post Group from Workflow Profile Properties Using JournalsEventHandler Business rule.
Does anyone have done this before? Is it possible to get the Journal Post Group from the Workflow Profile?
Solved! Go to Solution.
05-14-2024 01:18 PM
Golfstream has an example of getting the Approval security group. I have edited it but not tested but it should point you in the right direction:
Dim scenarioTypeId as Integer = BRApi.Workflow.General.GetScenarioTypeId(si, si.WorkflowClusterPk)
Dim currentProfile as WorkflowProfileInfo = BRApi.Workflow.Metadata.GetProfile(si, wfClusterPk.ProfileKey)
Dim workflowPostGroupKey as Guid = New Guid(currentProfile.GetAttributeValue(scenarioTypeId, SharedConstants.WorkflowProfileAttributeIndexes.JournalPostGroup))
Dim objGroupInfoEx As GroupInfoEx = BRApi.Security.Admin.GetGroupInfoEx(si, workflowPostGroupKey)
Dim jPostGroup as String = objGroupInfoEx.GroupInfo
05-14-2024 01:18 PM
Golfstream has an example of getting the Approval security group. I have edited it but not tested but it should point you in the right direction:
Dim scenarioTypeId as Integer = BRApi.Workflow.General.GetScenarioTypeId(si, si.WorkflowClusterPk)
Dim currentProfile as WorkflowProfileInfo = BRApi.Workflow.Metadata.GetProfile(si, wfClusterPk.ProfileKey)
Dim workflowPostGroupKey as Guid = New Guid(currentProfile.GetAttributeValue(scenarioTypeId, SharedConstants.WorkflowProfileAttributeIndexes.JournalPostGroup))
Dim objGroupInfoEx As GroupInfoEx = BRApi.Security.Admin.GetGroupInfoEx(si, workflowPostGroupKey)
Dim jPostGroup as String = objGroupInfoEx.GroupInfo
05-15-2024 04:19 AM
That worked. Thanks a lot!