Forum Discussion
Beeswing77
2 years agoNew Contributor III
Complex Expression in Transformation Rule - How to exit rule?
So we have a UD2 mapping set up in the List section.
What I want is to be able to set up a Complex Expression in the UD2 Composite section so that for certain accounts it does nothing and so moves ...
jwagner
2 years agoNew Contributor III
If you have a specified list of accounts you would like to be skipped in the Composite rule, you could use 'Globals.Bypass = True' in your rule, pseudocode below.
Dim accountsToSkip As List(Of String) = {<accounts to skip here>}
Dim sAccount As String = args.Value
If accountsToSkip.Contains(sAccount) Then
Globals.Bypass = True
Else
<Composite Rule logic>
End If
- Beeswing772 years agoNew Contributor III
That sounds like what I want, but I can't seem to get it to work for me. This is what I have now:
If args.GetTarget("A#") = "BS11200"
Globals.Bypass = True
Else
Return "None"
End IfIt just returns 0's in UD2 for account BS11200
- jwagner2 years agoNew Contributor III
Couldn't you just shift the list logic into the Complex Expression?
- Beeswing772 years agoNew Contributor III
Yes, in theory, but there are a lot of line in the List mapping. I'd also have to combine them with the source accounts, and there are many of those and they don't run in nice neat ranges. It wouldn't really be sustainable.