I would like to shut down the machine programatically. For that I would need to know how many programs are running. Also I would like to give the user an option of saving (if a word document is open). How do I get a list of all running programs i.e.open windows programatically through VB6? I have tried using the ‘SendKeys’ function but still could not manage to do it as I did not have a list of all open windows.