Home The Company Publications Products Links Tips

Tips, Tricks, and Techniques

Last update: 30 April 2004

Colors in the NATURAL Program Editor


I have an application which allows the user to select a NATURAL program from a list, and enter the Natural program editor. It automatically invokes the 'Scan' utility to find source lines with certain pre-determined character strings. The profile controls what color scanned lines become (usually red in our shop).
So far, so fine.
What is desired now is that the colors of the lines found by the scan be different colors based on the character string found. Is there anyone out there who is wise in the ways of the program editor who can give me a clue as to how to make this happen? Any help would be greatly appreciated. We are using NATURAL 2.2, SM 008, if that helps.

1st Answer

What is used at your shop: 3270-terminals or PCs emulating a 3270 thru IRMA, Attachmate's Extra!, etc.?
If your case is the latter, it might be easier to just set up the colors on the PC side. Just change color "red" to whatever else you wish in "Screen Colors" in Setup. However, if it's a 3270-screen, I can't think of an easy way of doing it...
Hope this helps!

2nd Answer

I can't think of any way that this could be done using the editor.
However, what you could do is to control your colours with %T and write a small application that behaves like the editor. It would read FUSER and use EXAMINE to search for the required strings and then highlight them in whatever colour you wish. I don't think this would be too difficult to write.

Top Page

Back to NATURAL Tips, Tricks, Techniques -- Overview