make afrange variables global