As long as there is at least a while-loop in your code, the VI should run as soon as you hit the run button (or CTRL+R) on the toolbar. And, it should open and run, automatically, in the executable version.
Apart from using the Close button (window's right-top corner), a front panel boolean button may be used to terminate the while-loop hence ending the VI execution.