We will add a standard button that will open a set of pre-built swipe-windows for the PD 850 module - and for fun, we will also create our own button that opens the same windows.
What we will build:
The below illustration shows what you will build in this tutorial. The red dots indicate tutorial steps.
Step 1: Adding a standard button that opens a PD850 swipe view.
Change default label text on "open view with pushbutton" to "PD850"
At this point you can start the graphical editor and place the button in a suitable place on the main view.
Step 2: creating a custom icon that opens a PD 850 swipe view.
Set view region - bottom right to y=50[mm] and x=50[mm]
The last thing you need to do is to make sure that the window opens, no matter where the user clicks on the button.
What your code should look like:
Now all mouse clicks or screen taps will go to the "open view in new window".
Step 3: Add your button to the main view
Start the graphical editor and place your two buttons in a suitable position. Your view should look something like this:
Step 4: Save, build and run your project.
Open your project ""XX_Temperature_Regulator_notification_project". Save, build project, start project downloader (make sure your test bed is still connected and that the PC device is started) and config all modules.
Open the different views and make sure to try the swipe functionality.