Try modified
DigitLedDisplay is an Arduino library for MAX7219 and MAX7221 8 bit 7-segment digital LED display module drivers.
Or you can copy DigitLedDisplay library to -> arduino\libraries\
Start From Digit: Default Value Zero
digitLedDisplay.printDigit(1234);