TechTalk: Required Field Exit

RPG
Typography
  • Smaller Small Medium Big Bigger
  • Default Helvetica Segoe Georgia Times

Required Field Exit

From: James Harr

To: All

Does anyone know the replacement for the S/36 required field exit? I've tried 'CHECK(FE)' but it still allows the user to tab out of the field. Any help would be appreciated.

From: Pete Hall

To: James Harr

I believe CHECK(FE) is the correct translation for S/36 required field exit. Actually, you could tab out of those guys on the S/36 too. The AS/400 handles the data transfer to the program a little differently though. Even if you don't right-justify a numeric value in a display file field, it still seems to magically get returned correctly somehow. Are you having some specific problem?

From: James Harr

To: Pete Hall

The problem is that though the field is used for input/output, numbers are passed to the field right-adjusted. If the user enters a number and tabs out, the field is returned to the program with the original value to the right, the entered value to the left, and everything in between padded with zeros by the program. Quite a frustrating problem!

From: Pete Hall

To: James Harr

I see what you mean. It may be that the best you can do is educate your users. Possibly you could define the display field with an M shift (decimal data returned in a character field), with a CHECK(RZ), and then do a TESTN on the returned value, but that would require handling the error within the application. I don't know how you can get the system to automatically trap it.

From: James Harr

To: Pete Hall

What I'll probably do is compare the returned value to the original, and send a soft message if the difference is greater than a certain percent. It's a shame DDS can't help me more.

BLOG COMMENTS POWERED BY DISQUS

LATEST COMMENTS

Support MC Press Online

$

Book Reviews

Resource Center

  •  

  • LANSA Business users want new applications now. Market and regulatory pressures require faster application updates and delivery into production. Your IBM i developers may be approaching retirement, and you see no sure way to fill their positions with experienced developers. In addition, you may be caught between maintaining your existing applications and the uncertainty of moving to something new.

  • The MC Resource Centers bring you the widest selection of white papers, trial software, and on-demand webcasts for you to choose from. >> Review the list of White Papers, Trial Software or On-Demand Webcast at the MC Press Resource Center. >> Add the items to yru Cart and complet he checkout process and submit

  • SB Profound WC 5536Join us for this hour-long webcast that will explore:

  • Fortra IT managers hoping to find new IBM i talent are discovering that the pool of experienced RPG programmers and operators or administrators with intimate knowledge of the operating system and the applications that run on it is small. This begs the question: How will you manage the platform that supports such a big part of your business? This guide offers strategies and software suggestions to help you plan IT staffing and resources and smooth the transition after your AS/400 talent retires. Read on to learn: