ok a restart sends open files to the hdd and a shutdown (not just turn the power off) should send it to the ram... but you can tell it to go to a page file instead.
if you want a program to open back up after a shutdown/ restart like for example a installer of some kind then you have to code it into the installer.
in the case of a WX updates-shutdown thats an override put in by Microsoft and does not look at what you are doing before kicking in so yes that can be a bitch but nothing you say, do or code into the system will make any difference.