In an email in March 2002, Nick Cox wrote that you could replace " as follows:
replace foo = subinstr(foo,`"""',"",.)
Take the second argument, which is the trickiest:
`"""' is `" as delimiter followed by " as character followed by "' as
delimiter. Make sure you start with ` (namely, a left or opening single
quote).
Using this logic with a macro using -file- and reading an ado text file
local line: subinstr local line `"""' "",all (this works)
But
local line: subinstr local line `"`"' "",all (produces "invalid syntax"
message)
local line: subinstr local line `"'"' "",all (produces "invalid syntax"
message)
Is this the way to code it? The problem could be within macro
interpretation, but macval() doesn't help.
Thanks,
Fred
Fred Wolfe
National Data Bank for Rheumatic Diseases
Wichita, Kansas
Tel (316) 263-2125 Fax (316) 263-0761 [email protected]