# Signature not working

**URL:** <https://community.silverfin.com/t/signature-not-working/2252>\
**Category:** Templates\
**Tags:** signmarker\
**Created:** [March 3, 2022, 2:24pm UTC](https://community.silverfin.com/t/signature-not-working/2252 "2022-03-03T14:24:48Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![lieels01](https://avatars.discourse-cdn.com/v4/letter/l/f08c70/32.png) [@lieels01](https://community.silverfin.com/u/lieels01)\
**Post date:** [March 3, 2022, 2:24pm UTC](https://community.silverfin.com/t/signature-not-working/2252/1 "2022-03-03T14:24:48Z")

</div>

Hi,

I’d like to add the signature of the statutory auditor in my file (if there’s one) and also add the name and representing person. I have the below code for this as it was in one of the Silverfin templates as well, but it’s not working… And I also guess there should be a much simpeler way to do this instead of the below code. Can you please advice?

{% comment %}get date\_av in correct date format{% endcomment %}  
{% assign date\_av = date\_av | date:"%Y-%m-%d" %}

{% stripnewlines %}  
{% for person in period.people %}  
{% assign show\_begin\_mandat = false %}  
{% assign show\_end\_mandat = false %}  
{% assign begin\_mandat = person.director\_start\_date | date:"%Y-%m-%d" %}  
{% assign end\_mandat = person.director\_end\_date | date:"%Y-%m-%d" %}  
{% if date\_av \>= begin\_mandat or begin\_mandat == blank %}  
{% assign show\_begin\_mandat = true %}  
{% endif %}  
{% if date\_av \<= end\_mandat or end\_mandat == blank %}  
{% assign show\_end\_mandat = true %}  
{% endif %}  
{% if show\_begin\_mandat and show\_end\_mandat and person.custom.function == 61 %}  
{% assign current\_signature = “” %}  
{% assign default\_type = “” %} {% comment %}check when person is legal or not{% endcomment %}  
{% if person.custom.represented\_by\_name != blank %}  
{% assign default\_type = “legal” %}  
{% else %}  
{% assign default\_type = “nature” %}  
{% endif %}  
{% assign type = person.custom.type | default:default\_type %}

{% assign street\_parts = person.address\_1 | split: ’ ’ %}  
{% assign number\_part = false %}  
{% assign number = “” %}  
{% assign street = “” %}  
{% for part in street\_parts %}  
{% assign part\_down = part | downcase %}  
{% if part contains “1” or part contains “2” or part contains “3” or part contains “4” or part contains “5” or part contains “6” or part contains “7” or part contains “8” or part contains “9” or part contains “0” or part\_down == “bus” %}  
{% assign number\_part = true %}  
{% else %}  
{% assign number\_part = false %}  
{% endif %}  
{% if number\_part %}  
{% assign number = number | append:" " | append:part %}  
{% else %}  
{% assign street = street | append:" " | append:part %}  
{% endif %}  
{% endfor %}  
{% assign street = street | strip %}  
{% assign number = number | strip %}  
{% capture address\_street %}{{ street | strip }}{% endcapture %}  
{% capture address\_number %}{{ number | strip }}{% endcapture %}  
{% assign person\_city = person.address\_2 | remove:“1” | remove:“2” | remove:“3” | remove:“4” | remove:“5” | remove:“6” | remove:“7” | remove:“8” | remove:“9” | remove:“0” | remove:“bus” | remove:“Bus” | remove:“BUS” | strip %}  
{% assign person\_postal\_code = person.address\_2 | downcase | remove:“a” | remove:“b” | remove:“c” | remove:“d” | remove:“e” | remove:“f” | remove:“g” | remove:“h” | remove:“i” | remove:“j” | remove:“k” | remove:“l” | remove:“m” | remove:“n” | remove:“o” | remove:“p” | remove:“q” | remove:“r” | remove:“s” | remove:“t” | remove:“u” | remove:“v” | remove:“w” | remove:“x” | remove:“y” | remove:“z” | remove:" " | strip %}

{% assign words = person.name | split: ’ ’ %}  
{% assign lastname = “” %}  
{% assign person\_first\_name = “” %}  
{% assign current\_signature = “” %}  
{% for word in words %}  
{% if forloop.last %} {% comment %}correct for syncs like adminis{% endcomment %}  
{% assign person\_first\_name = word %}  
{% else %}  
{% assign lastname = lastname | append:" " | append:word %}  
{% endif %}  
{% endfor %}  
{% if type == “legal” %}  
{% assign current\_signature = person.name %}  
{% else %}  
{% if person.custom.first\_name == blank and person.custom.last\_name == blank %}  
{% if after\_year\_2020 %}  
{% assign current\_signature = current\_signature | append:person\_first\_name | append:" " | append:lastname %}  
{% else %}  
{% assign current\_signature = person.name %}  
{% endif %}  
{% elsif person.custom.first\_name == blank and person.custom.last\_name != blank %}  
{% assign current\_signature = current\_signature | append:person\_first\_name | append:" " | append:person.custom.last\_name %}  
{% elsif person.custom.first\_name != blank and person.custom.last\_name == blank %}  
{% assign current\_signature = current\_signature | append:person.custom.first\_name | append:" " | append:lastname %}  
{% else %}  
{% assign current\_signature = current\_signature | append:person.custom.first\_name | append:" " | append:person.custom.last\_name %}  
{% endif %}  
{% endif %}

```
{% assign current_signature = current_signature %}

```

|{{ current\_signature }} {% if type == “legal” %}{% if person.custom.represented\_by\_name != blank %}  
met als vaste vertegenwoordiger {{ person.custom.represented\_by\_name }} {% endif %}{% endif %}{% if person.custom.represented\_by\_vat != blank %}  
{{ person.custom.represented\_by\_vat }}{% endif %}  
{% if person.custom.street == blank and person.custom.street\_number == blank %}{{ person.address\_1 }}{% elsif person.custom.street != blank and person.custom.street\_number == blank %}{{ person.custom.street }} {{ address\_number }}{% elsif person.custom.street == blank and person.custom.street\_number != blank %}{{ address\_street }} {{ person.custom.street\_number }}{% else %}{{ person.custom.street }} {{ person.custom.street\_number }}{% endif %}  
 {% if person.custom.postal\_code == blank and person.custom.city == blank %}{{ person.address\_2 }}{% elsif person.custom.postal\_code != blank and person.custom.city == blank %}{{ person.custom.postal\_code }} {{ person\_city }}{% elsif person.custom.postal\_code == blank and person.custom.city != blank %}{{ person\_postal\_code }} {{ person.custom.city }}{% else %}{{ person.custom.postal\_code }} {{ person.custom.city }}{% endif %}  
{% if person.custom.country == blank %}{% if person.custom.city != blank or person.address\_2 != blank or person\_city != blank %}{% unless current\_signature == blank %}België{% endunless %}{% endif %}{% else %}{{ person.custom.country }}{% endif %}  
|{% signmarker name:current\_signature email:person.custom.email phone:person.custom.phone\_number role:person.custom.function on\_behalf\_of:person.custom.represented\_by\_name %}  
{% newline %}  
{% endif %}  
{% endfor %}  
{% endstripnewlines %}  
{% comment %}end custom.av.show\_auditors{% endcomment %}

{{ warning\_signatures }}  
{{ signature\_av }}

{% comment %}PENNEO DOCUMENT LABEL{% endcomment %}  
{% result “signing\_doc\_name” “Ordinary shareholders meeting” %}

---

<div class="post-metadata">

**Author:** ![robindeclercq](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.silverfin.com/robindeclercq/32/472_2.png) [@robindeclercq](https://community.silverfin.com/u/robindeclercq)\
**Post date:** [March 3, 2022, 2:49pm UTC](https://community.silverfin.com/t/signature-not-working/2252/2 "2022-03-03T14:49:27Z")

</div>

Hi @lieels01 ,

Happy you tried to find a solution based on our Silverfin code 😃 , a bit unfortunate you couldn’t make it work.

Maybe before we dive into the code, could detail a bit more what you would like to accomplish? So in your template you would like to represent the statutory auditor name and representing person, together with a `signmarker`? You want it to look exactly like the template where you took the code from?

Also, I assume this code you shared is from the BE market? So the period.people drop will be populated by sync or via the template Bedrijfsparameters right?

Thanks for the feedback!

Kind regards,  
Robin

---

<div class="post-metadata">

**Author:** ![lieels01](https://avatars.discourse-cdn.com/v4/letter/l/f08c70/32.png) [@lieels01](https://community.silverfin.com/u/lieels01)\
**Post date:** [March 4, 2022, 3:08pm UTC](https://community.silverfin.com/t/signature-not-working/2252/3 "2022-03-04T15:08:51Z")

</div>

Hi @robindeclercq

That’s correct…  
Actually I’d like something really simple: a signature block where the name and representative of the statutory commissioner appears automatically.

---

<div class="post-metadata">

**Author:** ![lieels01](https://avatars.discourse-cdn.com/v4/letter/l/f08c70/32.png) [@lieels01](https://community.silverfin.com/u/lieels01)\
**Post date:** [March 6, 2022, 8:28pm UTC](https://community.silverfin.com/t/signature-not-working/2252/4 "2022-03-06T20:28:42Z")

</div>

Hi @robindeclercq ,

In the meantime I was able to make it a lot shorter and found this code that I can use. However, how can I make sure that only the statutory commissionor’s signature appears and not all of the people mentioned? I wanted to use {% if person.custom.function == 61 %}, but that doesn’t seem to do anything…

{% for person in period.people %}  
{% capture name %} **{{ person.name }}** {% endcapture %}  
{% assign names = names | append:name %}  
{% if person.custom.represented\_by\_name != blank %}  
{% assign names = names | append:"  
" | append:“Represented by " | append:person.custom.represented\_by\_name %}  
{% endif %}  
{% unless forloop.last %}  
{% assign names = names | append:”|" %}  
{% endunless %}  
{% endfor %}

---

<div class="post-metadata">

**Author:** ![Jelena\_Sutova](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.silverfin.com/jelena_sutova/32/599_2.png) [@Jelena\_Sutova](https://community.silverfin.com/u/Jelena_Sutova)\
**Post date:** [March 7, 2022, 1:34pm UTC](https://community.silverfin.com/t/signature-not-working/2252/5 "2022-03-07T13:34:54Z")

</div>

@lieels01

I have added the code which checks if person is Statutory auditor ( **{% if person.custom.function == 61 %}** ).  
If person is statutory auditor, the name and address is displayed:

> [@Details statutory auditor](https://community.silverfin.com/t/details-statutory-auditor/2253):
>
> Hi, I’d have liked to add some details such as the address and name about the statutory auditor. I have been searching for hours through several templates, but cant’ seem ti find anything. Can someone perhaps provide me with any tips? {% if herbenoeming\_commissaris %} {% assign nr = nr | plus:1%}{{nr}}. BESLIST het mandaat van de commissaris … met maatschappelijke zetel te … vertegenwoordigd door {% input custom.choice.board as:select options:“de heer|mevrouw” %} …, voor een periode van drie …

---

<div class="post-metadata">

**Author:** ![lieels01](https://avatars.discourse-cdn.com/v4/letter/l/f08c70/32.png) [@lieels01](https://community.silverfin.com/u/lieels01)\
**Post date:** [March 11, 2022, 8:45am UTC](https://community.silverfin.com/t/signature-not-working/2252/6 "2022-03-11T08:45:09Z")

</div>

Hi @Jelena_Sutova

Also solved by your reply in my other question. Thank you again!
