I am getting the following error message when I try to save/publish the workflow:
"Error publishing workflow. Unable to cast object of type 'System.Activities.InArgument`1[System.String]' to type 'System.Activities.InArgument`1[Microsoft.Activities.DynamicValue]'."
Is this the correct way:
I am running a Run If
First part is when MobilePhoneRequired field is ticked (Yes/No). In my case is "Yes"
Second part (Where the problem is - I think??)
Field: LineManager is a Person/Group
In Value I have put an email address from that person/group field.
I think here is where the problem is.
So basically Run the command IF: MobilePhoneRequired = YES and When the LineManger = email@example.com
Any advice please!
Solved! Go to Solution.
Now that I look into it, I dont think that's going to work as a person/group variable because it makes you declare it at the start of the WF and we don't want that. But you might be able to try it as a text variable.
Then inside it create a new text variable(not a person/group), call it whatever you want and have it equal the email address you want to use. Then in the runif set it equal to that variable.
Also, is the format of the email address correct? You use onmicrosoft?
I triedyour method. I think i done the way you described it.
The error message doesn't appear anymore but the manager doesn't receive the email.
Have created a Workflow Variable (text) called var_LMtxt)
See screenshot of the settings of "Run If"
try adding i:0#.f|membership| at the beginning of the email. I tested in my environment and you don't need to put in in a variable.
Also, add a "Log to History List" action right before the runif. Add a list lookup current item and pull whatever LineManager equals so you can see the value and see if it matches the managers email you're entering.