IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

RE :refresh panel


IBM Mainframe Forums -> TSO/ISPF
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
diwa_thilak

Active User


Joined: 13 Jul 2006
Posts: 205
Location: At my desk

PostPosted: Wed Dec 19, 2007 11:11 am
Reply with quote

Hi friends,

I have designed one panel, which will get three numbers and display their sum.

I am able to reitreve the values and so the calculation. But i could'nt able to display thier sum.

Also i need to incorporate teh following logic.

PF5 - It should refresh the panel.

Only after pressing PF3 - the panel should exit.

Below are the panel design and rexx code.

PANEL
Code:

 )ATTR                                                                   
        % TYPE(INPUT)  INTENS(HIGH) COLOR(TURQ) HILITE(USCORE) PAD(' ') 
        $ TYPE(OUTPUT) INTENS(HIGH) COLOR(RED)                           
        + TYPE(TEXT)   INTENS(LOW)  COLOR(GREEN)                         
        # TYPE(TEXT)   INTENS(LOW)  COLOR(YELLOW)                       
        @ TYPE(TEXT)   INTENS(LOW)  COLOR(BLUE)                         
 )BODY                                                                   
 #-------------------ONLINE ADD-DIV  QUERY TOOL------------------------ #
 +                                                                      +
 +                                                                      +
 @  @PLEASE PROVIDE ALL THE INFORMATION REQUIRED BELOW             @ @   
 +                                                                      +
 + NUMBER - I          :   %P  +   SUM : $ TV   +                       
 +                                                                      +
 + NUMBER - II         :   %D  +                                         
 +                                                                      +
 + NUMBER - III        :   %C  +                                         
 + +                                                                     
 + +       
++                                                                   
+PF1#HELP  +PF3#EXIT +PF5# CLEAR                                     
)INIT                                                                 
  &P=' '                                                             
  &D=' '                                                             
  &C=' '                                                             
  &TV = ' '                                                           
)REINIT                                                               
 REFRESH(*)                                                           
)PROC                                                                 
  &KEY = .PFKEY                                                       
  VPUT (P) SHARED                                                     
  VPUT (D) SHARED                                                     
  VPUT (C) SHARED                                                     
  VPUT (TV) SHARED                                                   
  VPUT (ZPFKEYS) SHARED                                               
  VER(&P,NB)                                                         
  VER(&D,NB)                                                         
  VER(&C,NB)                                                       
     
 )END   



REXX code

Code:
/* REXX */                                                     
 "PROFILE NOPREFIX"                                             
 MYLIB = 'A032945.REXX.PROGRAMS'                               
 "ISPEXEC LIBDEF ISPPLIB DATASET ID('"MYLIB"')"                 
 "ISPEXEC ADDPOP" /* OPTIONAL -> ROW(NN) COLUMN(NN) */         
 "ISPEXEC DISPLAY PANEL(TTPANEL)"                               
 "ISPEXEC REMPOP"                                               
 NV = '03'                                                                                                       
 ADDRESS ISPEXEC "VGET (P) SHARED"                             
 ADDRESS ISPEXEC "VGET (D) SHARED"                             
 ADDRESS ISPEXEC "VGET (C) SHARED"                             
 ADDRESS ISPEXEC "VPUT (NV) SHARED "                                                       
 EXIT   


The screen needs to stay active displaying the results. (here i have moved the static value to the result).

Let me know how to approach this issue.
Back to top
View user's profile Send private message
diwa_thilak

Active User


Joined: 13 Jul 2006
Posts: 205
Location: At my desk

PostPosted: Wed Dec 19, 2007 11:13 am
Reply with quote

Hi friends,

Onse small correction, in rexx code it is TV. I have incorrectly mentioned as NV.

Code is still a problem.
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2358
Location: Israel

PostPosted: Wed Dec 19, 2007 6:09 pm
Reply with quote

I don't see where the problem is.... simply sum the numbers, and display the panel again...

O.
Back to top
View user's profile Send private message
diwa_thilak

Active User


Joined: 13 Jul 2006
Posts: 205
Location: At my desk

PostPosted: Wed Dec 19, 2007 7:14 pm
Reply with quote

Ofer,

Thanks for your response.

Let me know how to make the panel stay alive till i press PF3 key ?

How to refresh the panel on pressing the PF5 key.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Wed Dec 19, 2007 7:51 pm
Reply with quote

Code:

****** ***************************** Top of Data ******************************
000001 /*REXX - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
000004 Trace "O"
000005 Address ISPEXEC "DISPLAY PANEL(ZTEST)"
000006 myrc = rc
000007 do  while ( myrc = 0 )
000008     f1 = strip(f1)
000009     f2 = strip(f2)
000010     t0 = f1 + f2
000011     Address ISPEXEC "DISPLAY PANEL(ZTEST)"
000012     myrc = rc
000013 end
000014 exit




Code:

)ATTR DEFAULT(%+_)
/*  % TYPE(TEXT) INTENS(HIGH)      defaults displayed for      */
/*  + TYPE(TEXT) INTENS(LOW)       information only            */
/*  _ TYPE(INPUT) INTENS(HIGH) CAPS(ON) JUST(LEFT)             */
$ TYPE(INPUT) INTENS(LOW) PAD(' ')    /* input field padded with '' */
! TYPE(INPUT) INTENS(LOW) PAD(' ')  /* input field padded with ' ' */
)BODY
%--------------------  TITLE FOR ENTRY PANEL  ----------------------------------
%COMMAND ===>_ZCMD                                                             +
%
+   Field 1         ....$F1     +
+   Field 2         ....$F2     +
+
+   Total           ....!T0     +
)INIT
)REINIT
)PROC
)END


Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> TSO/ISPF

 


Similar Topics
Topic Forum Replies
No new posts Execute secondary panel of sdsf with ... CLIST & REXX 1
No new posts Call program, directly from panel CLIST & REXX 9
No new posts panel creation question TSO/ISPF 12
No new posts Panel variable model line TSO/ISPF 3
No new posts REXX table content on panel will be r... CLIST & REXX 6
Search our Forums:

Back to Top