# How to increment index value by using trigger function

**URL:** <https://community.tulip.co/t/how-to-increment-index-value-by-using-trigger-function/7730>\
**Category:** General\
**Created:** [March 2, 2023, 11:20am UTC](https://community.tulip.co/t/how-to-increment-index-value-by-using-trigger-function/7730 "2023-03-02T11:20:40Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![preetham](https://avatars.discourse-cdn.com/v4/letter/p/f9ae1b/32.png) [@preetham](https://community.tulip.co/u/preetham)\
**Post date:** [March 2, 2023, 11:20am UTC](https://community.tulip.co/t/how-to-increment-index-value-by-using-trigger-function/7730/1 "2023-03-02T11:20:40Z")

</div>

Problem statement: Im using a connector with “get” method. So the output is in array of objects.  
Now in the app editor i had designed two screeens and a next button. First screen of the app should display the 0th index data and the second screen in the app should display the 1st index data. Now how should i write the trigger for next button to display the 1st index data in the screen.( I need the solution to increment the index value dynamically)

---

<div class="post-metadata">

**Author:** ![thorsten.langner](https://avatars.discourse-cdn.com/v4/letter/t/4bbf92/32.png) [@thorsten.langner](https://community.tulip.co/u/thorsten.langner)\
**Post date:** [March 2, 2023, 11:37am UTC](https://community.tulip.co/t/how-to-increment-index-value-by-using-trigger-function/7730/2 "2023-03-02T11:37:57Z")

</div>

Hi @preetham,

please dont open multiple threads on the same topic. I Will close this thread. So please stick to the original one.

Original: [How to declare array of objects in tulip connector function when there are many indexes in it - General - Tulip Community](https://community.tulip.co/t/how-to-declare-array-of-objects-in-tulip-connector-function-when-there-are-many-indexes-in-it/7699)

There you have a screenshot of how to setup the button trigger.  
If that is not enough please try to precisely tell where you stuck.

This is a pretty basic question (how to change a variables value by a button trigger). Maybe you should have a look in the knowledge base or tulip university on the basic use of tulip.

---

<div class="post-metadata">

**Author:** ![thorsten.langner](https://avatars.discourse-cdn.com/v4/letter/t/4bbf92/32.png) [@thorsten.langner](https://community.tulip.co/u/thorsten.langner)\
**Post date:** [March 2, 2023, 11:38am UTC](https://community.tulip.co/t/how-to-increment-index-value-by-using-trigger-function/7730/3 "2023-03-02T11:38:50Z")

</div>

Closed on March 2, 2023, 11:38am UTC


