Solved! Go to Solution.
I used the check syntax command and I did not have any syntax errors. However, I will try the double equal sign. It may be they are both allowable, but each has a different purpose. I am only hypothesizing, as I have only the experience I gained from my mistakes yesterday.
1. Create a workflow variable and have set near the beginning of the workflow, probably by a user via an activity
2. Use that variable value in any number of conditionals later in the workflow to branch the flow.
That's great... unfortunately, I don't have the experience with the coding to do this. So if anyone reads this post who does have that experience and can create some sample code for me to play with, I will be eternally grateful.
1) Create a variable in the workflow of type boolean.
2) Write your question name in the display name of that variable.
3) Add this variable to the activity you want, where it will be answered.(Will be ticked if yes)
4) Now the answer i.e. Yes or No will be saved in the boolean variable.
5) When you want to use it for further routing you can put a conditional block-
Select the Routing type- Conditional.
The Code is-
6) Here Userip is my variable Name.
And the options provided in result should be provided in Roting Events.
How can I use the conditional connector to route the process relative to a value returned from the primarybusiness object's attribute.
Regards and Thanks
1) You can create a variable in your workflow eg-IBAValue_EnggFuntion and use the below code to get the attributes of Primary buisness object. The first line of the code depends on the type of your buisness object in this case it is a problem report. In the code below the ViewByPath given is "Engineering_Function", this is the name of the attribute whose value you want to capture.
2) Once you get the attribute value in your workflow variable you can use that variable in conditional connector to route the process.
wt.change2. WTChangeIssue cm1 = (wt.change2.WTChangeIssue) primaryBusinessObject;
wt.iba.value.IBAHolder ibaHolder1 = (wt.iba.value.IBAHolder)cm1;
ibaHolder1 =wt.iba.value.service.IBAValueHelper.service.refreshAttributeContainer(ibaHolder1, null, null, null);
wt.iba.value.DefaultAttributeContainer attributeContainer =(wt.iba.value.DefaultAttributeContainer) ibaHolder1.getAttributeContainer();
wt.iba.definition.service.StandardIBADefinitionService defService = new wt.iba.definition.service.StandardIBADefinitionService();
wt.iba.definition.litedefinition.AttributeDefDefaultView attributeDefinition = defService.getAttributeDefDefaultViewByPath("Engineering_Function");
wt.iba.value.litevalue.AbstractValueView svc = attributeContainer.getAttributeValues(attributeDefinition);
IBAValue_EnggFuntion = svc.getLocalizedDisplayString();
Firstly; what should I select by the Type Name, when creating the variable?
Secondly; I have a soft type for the type "Reference Document" and the object type name is as follows:
I understand that I need to give the attribute name at the view by path. Is this the only place in the code that I change? does everything else stay the same?
That is very helpful. I can rename the variable and the results, but I still don't know how to set the variable in the first place and where.
You can define the variable globally by defining it in properties, when you edit a workflow template.
I have attached the screenshots..