[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now


Iseries automatic refresh screen

Posted on 2011-10-19
Medium Priority
Last Modified: 2012-06-21
I have this working to automatically refresh one screen, but I need it to refresh multiple screens.
Question by:nickmbnabb
  • 6
  • 3
  • 2
  • +1
LVL 16

Expert Comment

by:theo kouwenhoven
ID: 36996214
Can you explain a little more about what you mean by refresh and what with multiple screens,
What kind of program is it?
Does the program require user input?
or is it output only?

RPG or only CL?

A complete screen or messages only?

LVL 36

Expert Comment

by:Gary Patterson
ID: 36996270
Can you elaborate?

Author Comment

ID: 36996740
I have an input program, PROGRAM1, that adds to FILE1.  I have that file displaying on a screen at Location1

Location 1 and Location 2 is running my program which automatically refreshes the display of FILE1 as soon as PROGRAM1 adds to FILE1.   When I add to the file through the input program, I have succeeded in having the screen at Location1 instantly update.  But  Location 2 does not update automatically.
Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.


Author Comment

ID: 36996794
Let me try again, to be more clear.

I have input program adding to a file.

I have a display program displaying that file.

I have succeeded in having the display program instantly refresh and show the additions made through the input program.

However, if I start two separate instances of the display program, only one instantly refreshes.

Author Comment

ID: 36996803
By refresh I mean without any operator intervention, the screen updates.
LVL 27

Expert Comment

ID: 36996985
What mechanism (method) is used by the refresh program to know that it's supposed to refresh the screen?


Author Comment

ID: 36998531
I compiled the DDS using WAITRCD(5).  At first I had MAXDEV(1), thought maybe that was the problem, but changing it to a higher number did not help.

I use READ(E) and check for status 01331 to determine if there was no operator intervention.

Maybe there's an easier, cleaner method?   I'm having some other issues when there is operator intervention, but I believe I can work those out, hopefully.
LVL 16

Expert Comment

by:theo kouwenhoven
ID: 36999047
Hi Nick,

Did you add the INVITE to the screen (DDS) ?

See item on "Automatically Logging Off Inactive Workstations"
They use the same technique
you can find it on : http://www.itjungle.com/mgo/mgo052303-story01.html



Author Comment

ID: 36999071
Yes, I did.  
LVL 36

Expert Comment

by:Gary Patterson
ID: 36999750
Why not just post the code and dds so we can actually see what we are dealing with?
LVL 16

Accepted Solution

theo kouwenhoven earned 2000 total points
ID: 37000119
Hi nickmbnabb,

I tested the example myself and it runs great.
compiled the DDS with  WAITRCD(5)

A                                      DSPSIZ(24 80 *DS3)                    
A                                      CA01(01 'HELP')                       
A                                      CA03(03 'EXIT')                       
A                                      INVITE                                
A          R SCREEN1                                                         
A                                  1 19'TEST WAITRCD PARAMTER TO TIMEOUT D-  
A                                      ISPLAY'                               
A                                      DSPATR(HI)                            
A                                      DSPATR(UL)                            
A                                  9 28'INPUT:'                              
A            INPUT          1A  B  9 35                    
A                                 22  7'F3=EXIT'           
A                                      COLOR(BLU)          
A                                 14 28'Output:'           
A            COUNT          3  0O 14 36                    

Open in new window

FHKKPD     CF   E             WORKSTN Infds(Infds)                     
F                                     Maxdev(*File)                    
DInfDs            DS                                                   
D Status            *Status                                            
C                   Dow       *IN03 = *Off                             
C                   Write     Screen1                                  
C                   Read      HKKPD                                9999
C                   If         *In99 = *On And Status = 1331           
C                   Eval      COUNT += 1                               
C                   EndIf                                              
C                   Enddo                                              
C                   Eval      *Inlr = *On                              

Open in new window


Author Comment

ID: 37001103
Thanks, all, I saw where my issue was.  It WAS updating both screens, but because I was displaying the "new" records in a different color, the second screen was not recognizing it as new and put it with the "old" records.   It was a timing issue in my program.

Thanks to everyone for taking the time to help me out here.

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Microsoft Office Picture Manager was included in Office 2003, 2007, and 2010, but not in Office 2013. Users had hopes that it would be in Office 2016/Office 365, but it is not. Fortunately, the same zero-cost technique that works to install it with …
Applications for our next round of the Experts Exchange Scholarship Contest are starting to roll in. It made us wonder what our past winners are up to these days. Here's a look at what four winners experienced with the contest and what they're doing…
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
Suggested Courses
Course of the Month20 days, 4 hours left to enroll

872 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question