Completed seek function. Not fully debugged. Fixed a bug in open function.
Removed old commented out code.