find the first card in a list > Butler
Asked by haluk:

Hi, How can I:

When I move the "x" card to "b"

find the first card in list "c" ( I cant find that command on trello but in butler web page it seems)


Answers:
author: Iain Dooley
body: [@haluk](/t5/user/viewprofilepage/user-id/3775127) [@Ludo](/t5/user/viewprofilepage/user-id/3603216) this Trellinator function will post a comment containing the name of the first card in list named "c" to a card when it is moved into a list named "b":

<https://gist.github.com/iaindooley/a93023cb1f3dfe7e7c06d7f90d36b2bc>

comments: author: Iain Dooley
body: [@haluk](/t5/user/viewprofilepage/user-id/3775127) you can read more about Trellinator here:

<https://community.atlassian.com/t5/Marketplace-Apps-Integrations/Introducing-Trellinator-Automate-Trello-with-Google-Apps-Script/ba-p/925271>


author: Ludo
body: Hi

First select your trigger, then on the action butler panel, click on "cascade" tab (the last suggested tab)

comments: author: haluk
body: Thx for answer but at there there are only:

find the first last first card linked in the attachments

find a card titled with link titled

There are no other finding methot at there..

But at butler own panel: "<https://butlerfortrello.com/builder.html>"

there is "

find the first card in a list " {#toc-hId--1358966614}
------------------------------------------------------


author: Ludo
body: There are, look inside the command you have icons which allows additionnal options. Just click on.


author: haluk
body: ![1.png](https://community.atlassian.com/t5/image/serverpage/image-id/84136iF9DB97AD35A011E6/image-size/large?v=v2&px=999 "1.png")


author: haluk
body: ![2.png](https://community.atlassian.com/t5/image/serverpage/image-id/84137iFC8C00A75F00B03C/image-size/large?v=v2&px=999 "2.png")


author: haluk
body: I cant see any "more" buttons in here :(


author: Ludo
body: Indeed, you're right. It is not exactly the same rules. Actually the finding card commands are based on a name or a link. In general, it allows to do the job.

If you precise fonctional needs, probably we will find a solution for your use case.


author: haluk
body: ![2.png](https://community.atlassian.com/t5/image/serverpage/image-id/84138i47BF199BBA8736D9/image-size/large?v=v2&px=999 "2.png")


author: haluk
body: But as you see, in butlerfortrello web page, there is what I want.

I can use it from here?

or I can type custom rule manuelly?


author: Ludo
body: You must create commands with butler libraries without using butlerfortrello web page.


author: haluk
body: so if there is a way for what I want, please can you tell me how?. I need it a lot.


author: haluk
body: I need:

When I move a card from a list to another list...: (this is one card)

top of the card of a list need to move second list. (this is another card)


author: Ludo
body: First, you need to create a link beetwen the 2 cards.

A possible way just by adding one rule and one checklist,

Concerning the linking rule between 2 existing cards,

```
when an item is added to checklist "linked card" by anyone, 
find a card titled "{checklistitemname}" on board "Myboard", 
and link the cards together
```

Concerning the use case,

1. add a checklist named "linked card" in one of the 2 cards.
2. add an item in this checklist (item name = name of the card to link)

This last event will trigger the linking rule, you will obtain 2 linked cards what allows to synchronize the card movement.

```
when a card is moving to list "B", 
find the first card linked in the attachments, and move the card to the bottom of list "C" 
```

Just move a card in the list B and the linked card will be moved in the list C


author: haluk
body: yes I thought samething but. When I change the top card of the list... it wont take the first card , it will again same linked card so it will be very hard to manage what I want them to do... it will be very easy if only "move the first item of the list" :S


author: Ludo
body: Unfortunately, this command doesn't exist. If the first card of the list changes, you should define a new link and remove the old.


author: haluk
body: Also we can not manage "what can team members can see or not"... all of them is not logical for a like that program....


author: Ludo
body: trello is certainly a software which induces some constraints but which allows a high level of automation without having knowledge of programming. Personally, I don't know other equivalent tools except being able to develop a java application.

Finaly, if you have some technical skills, you will be interested by trellinator which improves trello capacities.