Added autorefresh feature