new open file code