Error in couple of lines of code and dont know how to add while loop??

Printable View