Some modifications to ToString method