trying to calculate when save, save is ok.