Hello,
I am using a macro to compare two versions of an rtf output for differences. My question is there a way to compress/remove control words such as /trowd or /setd using regular expressions so that when using proc compare to detect differences they will match up better. For example.
\trowd\trkeep\...etc..\cf1{Alfreq\cell}\pard\...cf1{1.6\cell}\pard…..\cf1{60\cell}{\row}
\trowd\trkeep\...etc..\cf1{Alice\cell}\pard\...cf1{1.5\cell}\pard…..\cf1{50\cell}{\row}
being turned into this
Alfreq ^^^ 1.6 ^^^ 60 ^^^
Alice ^^^ 1.5 ^^^ 50 ^^^
If you search lexjansen.com you'll find papers on this, e.g.
https://www.lexjansen.com/pharmasug-cn/2017/CC/PharmaSUG-China-2017-CC07.pdf
https://www.pharmasug.org/cd/papers/TT/TT13.pdf
But after skimming, I don't think I would do this in SAS. I'd be more likely to read the RTF's into MS Word, and use Word's compare feature. Which could probably be automated with VBA or whatever if needed.
If you search lexjansen.com you'll find papers on this, e.g.
https://www.lexjansen.com/pharmasug-cn/2017/CC/PharmaSUG-China-2017-CC07.pdf
https://www.pharmasug.org/cd/papers/TT/TT13.pdf
But after skimming, I don't think I would do this in SAS. I'd be more likely to read the RTF's into MS Word, and use Word's compare feature. Which could probably be automated with VBA or whatever if needed.
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—just $495!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.