fixed cmd string input. Thanks Brad Chapman