You can use the vi server to stop and close vi in memory. I have made a simple example that should get you started. It gets all the vis in memory and aborts them if they are running, then closes their front panel. It will leave itself open however.
Try it out. I think it'll be a good start, but be aware that it just closes the vis, whether that have changes or not.
Brian