How Can I send Commands form Nextion Display to Arduino Mega2560 ProjektCoktail

Hello my Name is Markus I'm from Germany. I am new in the world of Arduino an Nextion.
I want program an Cocktail machine. too choose the number of Program i made an Calculator in Nextion now I want to set an Relai high if i choose this Program but i have no idea how i can get the data from nextion into my if variable on the end of the Program.The data i get now form the nextion on arduino is in the picture but i have no plan how to import this data in my if value the other tow value in my if are for if there a glass or not and is it full or not

i send you my arduino code and my netion program file

i hope you can help me to fix this Problems

Nextion_num1__Relai_und_sensoren.ino (2.27 KB)