1. A method for controlling a peripheral device comprising: receiving a first code input; determining whether the first code input is valid; receiving a second code input if the first code input is determined to be valid, the second code input being a value associated with the first code input; determining whether the second code input is valid for the first code input; and executing a job generated from the valid first code input and second code input; wherein at least one of the receiving the first code input, the determining whether the first code input is valid, the receiving a second code input, the determining whether the second code input is valid and the executing is performed by a processor.