4-digits message code?

Hi guys! I wonder how to get that 4-digits message code when you enter 4 digits and the focus jumps to the other inputs fields automagically?