Added codes for Redo method.