added increments to file
replaced control.linepos with global variable.  Hopefully this will lead to less undefinable moments