Added replacing the selected tag when a tag is programed