Fix mismatched file name
Extract codes to save tab to a file