Try again:
Nick
[email protected]
> -----Original Message-----
> From: Nick Cox
> Sent: 19 July 2005 02:12
> To: '[email protected]'
> Subject: RE: RE: RE: reading the first X letters of a filename
>
>
> ssc inst fs
> fs *bilateral.csv
> foreach f in `r(files)' {
> insheet using `"`f'"'
> local country : substr local f "bilateral.csv" ""
> gen country = "`country'"
> ...
> }
>
> Nick
> [email protected]
>
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/