send UI events
use exit code to check if run app
change order of cpgf binding