Resolved issue #3 (save local file with counter)