[SOLVED]Supply with 12 volt into Vin pin and connect USB to computer for control

Should work fine. See the schematics for the Uno, 2009, etc. They all contain circuitry that detects the presence of (IIRC) a voltage of more than 7V on the Vraw pin and then disconnect the USB bus. So, if you plug a 9V power supply into the power inlet on the Uno board, the 5V power supply from the USB bus should get disconnected.

One way to test this is to look at the power LED on the Arduino board as you plug and unplug an external power supply or the USB cable. As long as one of the two is inserted (and your computer is on) the light should stay on.