modified ClearAll and RemoveRecord