When an attorney is changed, as provided in the last section, written notice of the change and of the substitution of a new attorney, or of the appearance of the party in person, must be given to the adverse party. Until then he must recognize the former attorney.