I figure if I can just change whichever registry key I have a script currently that opens the window and simulates clicking the set default button, but it is not ideal as it has to actually open the window.
Is write a script that will change which device is the default playback device, so if I push one of my extra keys on my keyboard it will change it to speakers, and if I push a different button, it will change it to headphones (or one button that will switch What I would like to do, as it is very annoying to have to go here every time I want to switch between my headphones and speakers, In the 'Manage Audio Devices' window by selecting the the desired device from the Playback tab and clicking Set Default. If you have something plugged in to both at the same time, it will only play out of the one that is set to be the default audio device.
Win 7 only allows playback out of one device (ie front or back audio jack) at a time.