This is the code for UI version. It could be ran in Windows environment