how to create list based on text argument from another screen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2024-10-16 1:40 PM
Hi there Touchgfx team!
I've these screen requirements
The user can select a test in the "test selection screen". Based on that selection, a "calibrate screen" will be created with different steps as you can see in the 3 images. I've mora than 30 test options and a set of different steps for each one.
How can I do this? I want to avoid the scenario of creating 30 different screens for each test. Is there a way to send the test option selected to the "calibrate screen", and based on that create the list of steps?
Thanks a lot in advance
Solved! Go to Solution.
- Labels:
-
TouchGFX
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2024-10-17 3:06 AM
Hello @JPabl.1,
You can create one screen for the "Calibrate Screen", and then set it up based on the test that has been selected. You can do that by transmitting the required settings between the screens. If you need to send a lot of data, then it would be better to send a flag or enum as you mentioned instead, and set the screen based on that.
The advantage of sending data is that you won't need to check any flags, and you just display the received data, but if there is too much data for transmission, then sending a flag is a cleaner method.
let me know if you have more questions!
ST Software Developer | TouchGFX
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2024-10-16 2:43 PM
I can think of:
1. I can create a enum for all the options.
2. Once the user selects an option, a flag is updated with the corresponding enum value.
3. On the "calibrate screen" setup function, this flag is checked to create the different version of the list.
Is that the correct way to do it or there's a better way? Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2024-10-17 3:06 AM
Hello @JPabl.1,
You can create one screen for the "Calibrate Screen", and then set it up based on the test that has been selected. You can do that by transmitting the required settings between the screens. If you need to send a lot of data, then it would be better to send a flag or enum as you mentioned instead, and set the screen based on that.
The advantage of sending data is that you won't need to check any flags, and you just display the received data, but if there is too much data for transmission, then sending a flag is a cleaner method.
let me know if you have more questions!
ST Software Developer | TouchGFX
