Added new function to set all values of Reg