# How to use Rules

**URL:** <https://community.origam.com/t/how-to-use-rules/4365>\
**Category:** start\
**Tags:** business-logic, tutorial\
**Created:** [January 22, 2026, 3:47pm UTC](https://community.origam.com/t/how-to-use-rules/4365 "2026-01-22T15:47:25Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![vikter](https://community.origam.com/user_avatar/community.origam.com/vikter/32/1903_2.png) [@vikter](https://community.origam.com/u/vikter)\
**Post date:** [March 25, 2026, 8:48am UTC](https://community.origam.com/t/how-to-use-rules/4365/3 "2026-03-25T08:48:20Z")

</div>

# More examples of using rules

## Condition rule for action buttons

If you need to conditionally display an action button for individual data records, for example, you can use an entity rule.

Here is an example in XPath using two custom XSLT functions (`ActiveProfileId` and `GetConstant`) that applies only to the current data record — `row` — whether in grid or form view in the client application:

`row/@refAssignedToId=AS:ActiveProfileId() and row/@refTaskStatusId != AS:GetConstant('TaskStatus_Done')`

This specific example displays the action button only if the current record is assigned to the currently logged-in user and at the same time the status is not equal (!=) to the “Done” state defined in a constant.

---

_[View the full topic](https://community.origam.com/t/how-to-use-rules/4365)._
