No announcement yet.

Showing a screen in a loop

  • Filter
  • Time
  • Show
Clear All
new posts

  • Showing a screen in a loop

    I need to prompt the user for a set of values - one per "station." The values for each station will be on one screen in the installer. I need to allow the user to enter x-number of stations, hence show them that screen x-number of times.

    How can I show the screen with two buttons "enter another" and "done entering" and (respectively) cause the screen to either show again to collect the next set of data for another station - or move on to the subsequent stage in the installer - depending on what they chose?

    Also, how would I store x-number of session variables as they enter them? What's the best collection (array, list, etc.) to use for this?


  • #2
    Is this possible in Setup Factory? I really hope so because it's very important to my setup. Any advice would be greatly appreciated!


    • #3
      It certainly is possible, using a custom screen. You will need to write some script for this, but it isn't a huge task.

      Arrays and lists are known as tables in Lua, so this is something you might want to sudy a bit.



      • #4
        I do understand that I'll be storing the values in a table(s). But I really have no idea whatsoever as to how to get have the two buttons I described above either loop back to show the screen again for additional input - or move forward in the installation. Could you please guide me as much as possible on this?

        Thank you very much.


        • #5
          Actually, there is no need to jump or loop screens. Instead, you stay on a single screen and update the captions.

          Click image for larger version

Name:	SCRN-2015-05-28-01.png
Views:	1
Size:	35.8 KB
ID:	284316

          This custom screen allows to enter an unlimited amount of items, but none of them can be left blank. Afterwards, in a screen exclusively for debugging purposes, you can see the first 16 items entered. What exactly you do with them later is entirely up to you.

          Click image for larger version

Name:	SCRN-2015-05-28-02.png
Views:	1
Size:	40.3 KB
ID:	284317

          This isn't an overly complicated issue, but you definitely should start learning with simpler custom screens, understand the control IDs and messages they generate, and how you react to them before you get to more complicated interactions like in this project.