added checking of blanks and autofocus