Although InDesign comes with a variety of form elements, it doesn't include a counter that can be increased or decreased by clicking on it. Instead of using a form element, you can make your own interactive counter using a multi-state object (MSO) and buttons.



Create an MSO from the values

  1. Make a text frame for the first value and set its Paragraph alignment to Align center.
  2. Go to Object > Text Frame Options... and in the General section of the Text Frame Options dialog under Vertical Justification, set Align to Center.
  3. Duplicate the text frame as many times as needed for the values you want to include and update the values.
  4. Reorder the layers (if necessary) so that the number you want to appear first is on the top of the layer stack.
  5. Align the text frames vertically and horizontally.
  6. With the text frames selected, go to Window > Interactive > Object States and click on the + button at the bottom of the panel to convert the selection into a multi-state object.


Create the increase and decrease buttons

1. Create an up arrow (you can use a caret) and size it as needed.

2. With the up arrow selected, go to Window > Interactive > Buttons and Forms.

3. Apply the following settings:

  • Type: Button
  • Event: On Release or Tap
  • Actions (click the + to add an action): Go To Next State
  • Object: [select the name of the counter MSO that you just created]
  • Select Stop at Last State

4. Copy and paste the arrow button.

  • Note: When you copy and paste a button, InDesign removes the duplicated button's actions. If you duplicate it using Edit > Duplicate or Alt (Windows)/Option (macOS) + drag to duplicate it, then you'll need to select the duplicated button's action and click the - (minus) button to remove it).

5. Flip it vertically (Object > Transform > Flip Vertical) to make a down arrow.

6. With the duplicated button selected, set the following settings in the Buttons and Forms panel:

  • Type: Button
  • Event: On Release or Tap
  • Actions (click the + to add an action): Go To Previous State
  • Object: [select the name of the counter MSO]
  • Select Stop at First State


Use the counter to increment other content

There are a couple of different ways that you can make the counter increment other content. You could add manually updated content to the object states of the MSO that contains the numbers for the counter or you could add another action to the counter's buttons.


Add content to the counter MSO


1. Make the content that corresponds to each of the values in the counter MSO.

2. Add the content to an object state in the existing MSO by doing the following:

  • Select the content that matches the first value.
  • Shift + select the Counter MSO with the content's corresponding value visible to add it to the selection
  • In the Object States panel, click the Add objects to visible state button at the bottom of the Objects States panel.

3. Repeat step #2 for each corresponding piece of content.


Connect the counter to another MSO

You can use this counter to increment or decrement content in another MSO by creating another MSO with the same number of object states with content that corresponds to the counter and by adding another action to each of the counter's buttons.

1. Make another MSO with the same number of object states as the counter and adjust the values manually in that MSO to correspond with the counter.

2. Select the counter's up arrow button and update the following settings:

  • Actions (click the + to add a second action): Go To Next State
  • Object: [select the name of the new MSO that you just created]
  • Select Stop at Last State

3. Select the counter's down arrow button and update the following settings:

  • Actions (click the + to add a second action): Go To Previous State
  • Object: [select the name of the new MSO that you just created]
  • Select Stop at First State


Saving data

Instead of an MSO counter, use one of InDesign's built-in form elements in conjunction with the in5 Form Element Data interactive widget (in5 > Interactive Widgets > Form Element Data) to save data locally.

See Saving form data locally using in5.