07-20-2023 10:55 AM
Hi - I am trying to get the confirmation entities from all of my Import Channel under my WF Profile. using extender BR but I am not able to find an instance to call the function. Any help would be appreciated ?
I was able to get the Confirmed entitles at the WF Profile Level and the below is the code.
Dim A As String = String.Empty
Dim wfClusterPk As WorkflowUnitClusterPk = BRApi.Workflow.General.GetWorkflowUnitClusterPk(si,"Total_Corporate","Actual","2023M1")
Dim objList As List(Of BaseNameIntPairInfo) = BRApi.Workflow.Metadata.GetProfileConfirmationEntities(si,wfClusterPk)
For Each cent As BaseNameIntPairInfo In objList
A = cent.Name
brapi.ErrorLog.LogMessage(si,A)
Next
07-20-2023 11:36 AM
Hi @Krishna Make sure you got this selected in your Workflow Calculation Definition
The use the Snippet Editor for the syntax.
Hope this helps.
07-20-2023 11:43 AM
Thanks Mike. I am using extender rule and there is no api. It should be Brapi. Btw the Confirmation entities are checked.
07-20-2023 11:49 AM
OK, not sure why you want to do that. Did you find this Dashboard Extender - Snippet, there are code helpers to run a Confirmation and to get the ConfirmInstanceInfo.
Good luck, if you provide more information on the end game I'm interested to know what you are trying to solve.
Hope this helps,
07-20-2023 11:55 AM
Thanks for your quick response. I will research more. I have created a Formeventhandler and each form has its own entity and I am trying to read the confirmation entity and pass it to verify a cell amount. Make it dynamic vs Hard coding the entities.
07-20-2023 11:58 AM
If there is one and only Entity for each Form task, consider entering that 1 Entity as the |WFText1| property, on that Scenario Type on the Workflow Forms task. Easy to grab by way of code in the EventHandler.
07-20-2023 03:43 PM
Thanks for the suggestion. Below is the code
Dim A As String = String.Empty
Dim B As String = String.Empty
Dim C As String = String.Empty
For Each wpf As WorkFlowProfileInfo In objList
B = (wpf.Name.Split(".")(1)).Trim
'brapi.ErrorLog.LogMessage(si,B)
' C= B.Split(wpf.Name,"." (1))
If wpf.Name.StartsWith("USA") Then
'brapi.ErrorLog.LogMessage(si,wpf.Name.Length)
A = wpf.GetAttributeValue(ScenarioTypeId.Actual,sharedconstants.WorkflowProfileAttributeIndexes.Text1)
If a.Length > 1 Then
brapi.ErrorLog.LogMessage(si, "WFName---" & wpf.Name & "---TextValue---" & A)
End If
End If
Next