Hi all;

I have been using STATA in the past couple of years and developed lots of codes so far in both do and ado files. I wanted to see how I can convert the ado/do files into txt files (not manually by copying and pasting but saving or exporting if they work for do/ado files). The bigger purpose of this work is that I would like to analyze all my codes to see the frequency of each command I used. I think that can be best done by converting the do/ado codes into texts, reading txt files, and counting each command entered as string variables.

Does anyone know how I can convert do/ado file codes into txt?

Thanks