Temperature control program

Hello
I have a heating program of a resistance that works with a potentiometer to set the temperature, and with a second I measure the temperature (two programs Flowcode V6 that I have to compile on an Arduino card). Except that I would need a program to regulate the temperature according to the temperature display on the measurement program but I do not get there, so if someone can help me.
Enclosed you have my two programs: