Before running Real program you have get the last reload time of the application then you are able to give a QVD team to refresh the QVD.
By a variable you can store the last reload time in time stamp
Let vReloadtime = Reloadtime();
When you get the time in variable take a variable in any text box and give information about last reload time of the application according to last reload time whenever it is not completed the QVD scheduler not start. So based on the scheduler give reload refresh time to the QVD generator.