adding dynamic refresh