Save a view to a file