Several of you wrote with questions about my last tip of highlighting source code. The following tip is more of a clarification, as well as a couple suggestions from some other Search400 readers.
Many of you wrote that although the emphasized source worked well in CL, DDS and RPG III, it didn't appear to work in an RPG IV program. Even though you can't see the hex codes in your source file, the hex codes have to be in the part of the screen that is displayed on your CRT in order for the source to be emphasized. When SEU displays source code in an RPGLE type source member, it shifts the viewing area over to the right by a few characters. In my original example (viewable at Search400), the hex characters would be off to the left in an RPG IV program and not displayed in the viewable area of the screen. To correct this, move the starting position of the first two fields in the data structure (FLD1 and FLD2) to be seven characters farther to the right.
Jason McMicking from Mount Vernon Mills adds this tip so that you can key hex values directly into your source code using client access via a customized keyboard map. This will be helpful to those of you who wrote that you don't program in RPG but would still like to highlight your source.
"Another method besides copying the hex values is to map the hex values to your emulation session. In your client access emulator, go to keyboard setup under assist and select customize keyboard. Then say you wanted hex 22(highlight) applied to ctl + F2, you would map APL 22 as the action for CTL F2. Then when you comment a line and press Ctl + F2 the remainder of the line will be highlighted. Using apl will give you the hex equivalent of the number after, which works on commented lines in SEU. I've encountered problems when I put these values prior to position 6 or on an uncommented line."
As a side note, when you enter the APL 22 (or other hex code that you want) into the client access keyboard map, make sure it is not enclosed in [brackets] like many of the other mapped keys in client access.
Chuck Minarik, a systems analyst from Penske Truck Leasing in Reading, Pa., adds: "It's also helpful to point out that you can intersperse regular and emphasized (high-intensity, underline, etc.) text on the same line by returning back to normal text with hex code 20. A good source for a table of attribute bytes for 525x displays is Chapter 3, titled "Field Attribute Codes," in IBM's manual:
Personal Communications 5250
Document Number SC41-3553-01
Tim Granatir is vice president of Technical Services at Interlink Technologies in Maumee, Ohio, where he serves as chief architect for the company's warehouse management system. He has worked in the banking, insurance, healthcare and distribution industries in various positions, including programmer/analyst, systems analyst and DP manager. Tim has worked on IBM midrange platforms since 1983.