# Expression Tag / if condition third tag

**URL:** <https://forum.inductiveautomation.com/t/expression-tag-if-condition-third-tag/83722>\
**Category:** Ignition\
**Tags:** ignition81, perspective\
**Created:** [January 3, 2024, 7:45am UTC](https://forum.inductiveautomation.com/t/expression-tag-if-condition-third-tag/83722 "2024-01-03T07:45:24Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [January 3, 2024, 10:23am UTC](https://forum.inductiveautomation.com/t/expression-tag-if-condition-third-tag/83722/2 "2024-01-03T10:23:02Z")

</div>

```auto
case(
    binEnc({tag1}, {tag2}, {tag3}),
    1, "Tag1 is positive.",
    2, "Tag2 is positive.",
    3, "Tag1 and 2 are positive.",
    4, "Tag3 is positive.",
    5, "Tag1 and 3 are positive.",
    6, "Tag2 and 3 are positive.",
    7, "Tag1, 2 and 3 are positive.",
    "No tag is positive."
)

```

[https://docs.inductiveautomation.com/display/DOC81/binEnc](https://docs.inductiveautomation.com/display/DOC81/binEnc)

[https://docs.inductiveautomation.com/display/DOC81/case](https://docs.inductiveautomation.com/display/DOC81/case)

See also, [Wiki - how to post code on this forum](https://forum.inductiveautomation.com/t/wiki-how-to-post-code-on-this-forum/77831)

---

_[View the full topic](https://forum.inductiveautomation.com/t/expression-tag-if-condition-third-tag/83722)._
