added autocomplete method