Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Issue while passing variable from COBOL to ISPF PANEL

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF
View previous topic :: :: View next topic  
Author Message
Priti1.n

New User


Joined: 13 Jan 2012
Posts: 2
Location: India

PostPosted: Fri Jan 13, 2012 6:24 pm    Post subject: Issue while passing variable from COBOL to ISPF PANEL
Reply with quote

Hi Iam displaying ISPF panel through Cobol program. as follows:
CALL 'ISPLINK' USING ISPF-DISPLAY ISPF-PANEL-5

where ISPF-DISPLAY =Display and ISPF-PANEL-5 is my panelname.

In the panel I want to display a warning message based on a condition in cobol program.
To achieve this Iam using follow code;

CALL 'ISPLINK' USING ISPF-VDEFINE ISPF-WRNGA FP-WRNGA
ISPF-CHAR BY CONTENT LENGTH OF FP-WRNGA

here FP-WRNGA is my function pool variable and ISPF-WRNGA holds the name of panel varaible in which error msg is to be populated.

Iam moving my message to function pool variable:

MOVE WS-PNLA-WRNG1 TO FP-WRNGA

However this message is not getting displayed on the panel.

My panel is coded as follows:

Code:
)ATTR                                                                   
                                           
  ¦ TYPE(TEXT) INTENS(NON)                                             
  ? TYPE(OUTPUT) INTENS(LOW)                                           
                                             
)BODY                                                                   
%--------------------- Confirmation for Event Completion ---------------
%COMMAND ===>_ZCMD                                                     
+
+
+
¦|----------------------------------------------------------------------
¦| WARNING!    ?WRNGA                                                       
¦|----------------------------------------------------------------------
+        %PF3  +to end this panel without completing the event
)INIT                                                         
    IF (&OPT = 'Z')                                                 
        .ATTRCHAR(¦) = 'TYPE(TEXT) INTENS(HIGH)'                     
       .ATTRCHAR(?) = 'TYPE(OUTPUT) INTENS(HIGH) COLOR(&CLR)'       
       .ATTR(T)     = 'TYPE(INPUT) INTENS(HIGH)'                   
       .ALARM = YES   
)PROC                       
)END
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10327
Location: italy

PostPosted: Fri Jan 13, 2012 6:46 pm    Post subject: Reply to: Issue while passing variable from COBOL to ISPF PA
Reply with quote

why reinvent the wheel...

use the SETMSG ISPF function

fill the ISPF variables

zedsmsg for the short message ( will be displayed in the upper right corner of the screen )
zedlmsg
for the long message ( which will be displayed according to the ISPF settings hitting the PF1 after the short message has been displayed)

and invoke the ISPF function SETMSG MSG(ISRZ001)

and if things have been setup properly hitting again PF1 will show the relative HELP panel
Back to top
View user's profile Send private message
Priti1.n

New User


Joined: 13 Jan 2012
Posts: 2
Location: India

PostPosted: Fri Jan 13, 2012 7:36 pm    Post subject:
Reply with quote

Thanks Enrico, But I can not use this functionality as my panel contain some other data as well and it should display this message at the bottom and receive user's response.
based on user's responce I have to do further processing.

e.g: DO YOU WANT TO CONTINUE (Y/N): __

I had used above approach earlier but i know that iam missing something here but do not recollect it.

Can anyone help in this approach or suggest alternate method by which I can display a conditional message and receive user's response.
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2086
Location: Silicon Valley

PostPosted: Sat Jan 14, 2012 12:45 am    Post subject: Reply to: Issue while passing variable from COBOL to ISPF PA
Reply with quote

In your COBOL, try VPUT to SHARED

And in your panel, issue VGET from SHARED.
Back to top
View user's profile Send private message
don.leahy

Active Member


Joined: 06 Jul 2010
Posts: 658
Location: Whitby, ON, Canada

PostPosted: Sat Jan 14, 2012 1:42 am    Post subject:
Reply with quote

Use Dialog test. If you set a breakpoint before your DISPLAY command you can look at the variable pools to see where your value is.
Back to top
View user's profile Send private message
Stefan

Active User


Joined: 12 Jan 2006
Posts: 110
Location: Germany

PostPosted: Mon Jan 16, 2012 9:18 pm    Post subject:
Reply with quote

Pedro is right. When using a compiler language, you have to use VPUT/VGET services to interact with ISPF panels. ISPF is able to access and manipulate the variables used by the REXX interpreter and by the CLIST command processor. So only for these languages you might avoid the use of VPUT/VGET services.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SIGNAL ON HALT issue packerm CLIST & REXX 0 Fri Oct 20, 2017 6:56 pm
No new posts IEW2456E error when link-editing a C ... Senthilraj JCL & VSAM 0 Fri Oct 13, 2017 3:12 pm
No new posts MQ command in option 6 of ISPF! Vignesh Sid All Other Mainframe Topics 3 Tue Sep 26, 2017 6:01 pm
No new posts Assembler Macro Copybook converted to... Ziquilix PL/I & Assembler 4 Tue Sep 26, 2017 3:07 am
No new posts Conditional highlighting of rows in I... packerm CLIST & REXX 2 Thu Sep 21, 2017 6:50 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us