# Boolean default value

**URL:** <https://community.silverfin.com/t/boolean-default-value/194>\
**Category:** Templates\
**Tags:** variables, attribute\_default, attribute\_boolean\
**Created:** [April 3, 2017, 12:45pm UTC](https://community.silverfin.com/t/boolean-default-value/194 "2017-04-03T12:45:19Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![marnixcoudre](https://avatars.discourse-cdn.com/v4/letter/m/8edcca/32.png) [@marnixcoudre](https://community.silverfin.com/u/marnixcoudre)\
**Post date:** [April 3, 2017, 12:45pm UTC](https://community.silverfin.com/t/boolean-default-value/194/1 "2017-04-03T12:45:19Z")

</div>

Dear,

I created a boolean in form working\_docs with the code below.

{% input custom.boolean.provision as:boolean default:‘true’ %}

In another form I want to use the input of this boolean in an if-function and want that my elsif is fullfilled if the boolean is true (default). The problem is that my elsif is only fullfilled if I untich the boolean first and thick it again but not when I do nothing and leave the boolean at its default value.

So it seems that my if-function does not recognise the default value. Does anyone has a solution for my issue?

{% if period.reconciliations.working\_docs.custom.boolean.provision != ‘true’ %}

{% elsif period.reconciliations.working\_docs.custom.boolean.provision != ‘false’ %}

Thanks

---

<div class="post-metadata">

**Author:** ![Mathias](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.silverfin.com/mathias/32/125_2.png) [@Mathias](https://community.silverfin.com/u/Mathias)\
**Post date:** [May 11, 2017, 9:05am UTC](https://community.silverfin.com/t/boolean-default-value/194/2 "2017-05-11T09:05:24Z")

</div>

Hello @marnixcoudre

When a boolean is not ticked, the default value will indeed not be saved. The value of the boolean is blank in the case of a default.

This can be solved by integrating this blank value in your if-function. For example (for use in same template):

```auto
{% input custom.boolean.provision as:boolean default:'true' %}
{% if custom.boolean.provision == 'true' or custom.boolean.provision == blank %}
{% elsif custom.boolean.provision == 'false' %}
{% endif %}

```

For your code could you please try with:

```auto
{% if period.reconciliations.working_docs.custom.boolean.provision != 'false' or period.reconciliations.working_docs.custom.boolean.provision == blank %}

```

Please let us know if this does not solve the issue.

Kind regards,

Mathias

---

<div class="post-metadata">

**Author:** ![Jasper](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.silverfin.com/jasper/32/2189_2.png) [@Jasper](https://community.silverfin.com/u/Jasper)\
**Post date:** [October 10, 2023, 10:10am UTC](https://community.silverfin.com/t/boolean-default-value/194/3 "2023-10-10T10:10:34Z")

</div>

Hello,

Is it possible to set the value of a boolean in a reconciliation from the configuration box?

Kind regards  
Jasper

---

<div class="post-metadata">

**Author:** ![Michiel](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.silverfin.com/michiel/32/2364_2.png) [@Michiel](https://community.silverfin.com/u/Michiel)\
**Post date:** [October 10, 2023, 10:20am UTC](https://community.silverfin.com/t/boolean-default-value/194/4 "2023-10-10T10:20:17Z")

</div>

Hi Jasper,

In certain cases it’s possible to set the default value of a boolean in a marketplace reconciliation template from the configuration box in your firm.

To be able to do that, the default of an input field must be a local variable. In the configuration box you can then assign a value to that local variable. To find out which input fields in marketplace reconciliation templates are applicable for configuration, I refer to are our [support page](https://support.silverfin.com/nl/support/solutions/articles/101000408117-hoe-configureer-ik-verschillende-templates-).

Kind regards,

Michiel
