Topic
  • 3 replies
  • Latest Post - ‏2013-02-04T21:44:33Z by Matt-FNIS
Matt-FNIS
Matt-FNIS
43 Posts

Pinned topic IF statement not propertly evaluating return from boolean Method builder

‏2013-02-04T16:48:36Z |
I have a Method builder called methodX with Return Type=boolean. I have an Action List builder with an IF statement that evaluates the result of methodX as IF ${MethodCall/methodX} THEN. This test always fails (i.e., tests as false) even when methodX returns true. Why is this not working? I've tried all combinations of Comparison As options (automatic, as strings, as numbers) with all the appropriate comparison values (1, true) and none of them work. What is the proper way to evaluate the return code from a boolean method in an Action List?
Updated on 2013-02-04T21:44:33Z at 2013-02-04T21:44:33Z by Matt-FNIS
  • Matt-FNIS
    Matt-FNIS
    43 Posts

    Re: IF statement not propertly evaluating return from boolean Method builder

    ‏2013-02-04T16:53:02Z  
    Using WEF 7.0.1.4
  • mburati
    mburati
    2570 Posts

    Re: IF statement not propertly evaluating return from boolean Method builder

    ‏2013-02-04T18:09:48Z  
    Personally, I try to use Action Lists only for dispatching to methods/pages and not for more complex conditional logic, where it's more clear what's going on in a Method/LJO builder.

    Try the attached model if you really need to do the conditional in an action list, and see if that works for you.

    I hope that info helps,
    ..Mike Burati
    http://www-10.lotus.com/ldd/pfwiki.nsf/
    The postings on this site are my own and do not necessarily represent the positions, strategies, or opinions of IBM.
  • Matt-FNIS
    Matt-FNIS
    43 Posts

    Re: IF statement not propertly evaluating return from boolean Method builder

    ‏2013-02-04T21:44:33Z  
    • mburati
    • ‏2013-02-04T18:09:48Z
    Personally, I try to use Action Lists only for dispatching to methods/pages and not for more complex conditional logic, where it's more clear what's going on in a Method/LJO builder.

    Try the attached model if you really need to do the conditional in an action list, and see if that works for you.

    I hope that info helps,
    ..Mike Burati
    http://www-10.lotus.com/ldd/pfwiki.nsf/
    The postings on this site are my own and do not necessarily represent the positions, strategies, or opinions of IBM.
    Yes, that construct works. Thank you.