Portal | IBM Manuals | Downloads | Products | Refer | Info | Programs | JCLs | Forum Rules*| Site Map | Mainframe CD 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index
 
Register
 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index FAQ Search Memberlist Usergroups Profile Log in to check your private messages Log in
 
Displaying Error Messages in Panels
Goto page Previous  1, 2
 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF
Author Message
malathy_tv

New User


Joined: 29 May 2007
Posts: 24
Location: chennai

PostPosted: Fri May 02, 2008 11:37 am    Post subject:
Reply with quote

Hi,

Its not a Member in the PDS it is like a msg id inside some member, this member is present in the PDS PDS.MSGLIB

and i was able to see the PDS PDS.MSGLIB using ISRDDN

EX:

MAL002 'INVALID OPTION'

MAL004 'INVALID STATE NUMBER'
Back to top
View user's profile Send private message
References
PostPosted: Fri May 02, 2008 11:37 am    Post subject: Re: Reply with quote

malathy_tv

New User


Joined: 29 May 2007
Posts: 24
Location: chennai

PostPosted: Fri May 02, 2008 11:42 am    Post subject:
Reply with quote

Hi,

MAL004 is not a member it is like the MSGID, it is present inside one of the member of the PDS.MSGLIB library

i was able to see only that the PDS.MSGLIB getting concatenated with the ISPMLIB using ISRDDN

Example of the MSGID present inside the member:

MAL002 'INVALID OPTION'

MAL004 'INVALID STATE NUMBER'
Back to top
View user's profile Send private message
malathy_tv

New User


Joined: 29 May 2007
Posts: 24
Location: chennai

PostPosted: Fri May 02, 2008 5:17 pm    Post subject:
Reply with quote

Hi,

i found one method of populating the error message that is by using ZEDMSG

here am throwing the panels to get the input, validate in rexx and throw the error message

as UmeySan said i used this do while loop but when i do this am not able to check and validate both of my input on the same time

if either of these is correct it comes out without checking the other all this is because of using DO WHILE STA > 0 and setting the value to zero after every check but if i didnt do that am not getting the erro message as i said previously

/*REXX*/

STA = 9
DO WHILE STA > 0
ZEDSMSG = " "
ADDRESS ISPEXEC
"ADDPOP ROW(24) COLUMN(60)"
"DISPLAY PANEL ("PANEL")"
AGN_CHK:
A3 = VERIFY(AGN,XRANGE('0','9'))
IF A3 = 0 THEN STA=0
ELSE ZEDSMSG = 'INVALID AGENCY NUMBER'
"ISPEXEC SETMSG MSG(ISRZ001)"
RETURN
STE_CHK:
A4 = VERIFY(STE,XRANGE('A','Z'))
IF (A4 = 0 & LENGTH(STE) = 2 )THEN STA=0
ELSE ZEDSMSG = 'INVALID STATE CODE'
"ISPEXEC SETMSG MSG(ISRZ001)"
RETURN

so what can be done on this regards

Thanks in advance.
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 322
Location: work

PostPosted: Sat May 10, 2008 4:37 am    Post subject: Reply to: Displaying Error Messages in Panels
Reply with quote

Regarding your program:
Code:

/*REXX*/                                   
STA = 9                                   
DO WHILE STA > 0                           
ZEDSMSG = " "                             
ADDRESS ISPEXEC                           
"ADDPOP ROW(24) COLUMN(60)"               
"DISPLAY PANEL ("PANEL")"                 
AGN_CHK:                                   
A3 = VERIFY(AGN,XRANGE('0','9'))           
IF A3 = 0 THEN STA=0                       
ELSE ZEDSMSG = 'INVALID AGENCY NUMBER'     
"ISPEXEC SETMSG MSG(ISRZ001)"             
RETURN                                     
STE_CHK:                                   
A4 = VERIFY(STE,XRANGE('A','Z'))           
IF (A4 = 0 & LENGTH(STE) = 2 )THEN STA=0   
ELSE ZEDSMSG = 'INVALID STATE CODE'       
"ISPEXEC SETMSG MSG(ISRZ001)"             
RETURN                                     



1. I think you need an END statement to match the DO WHILE
2. your panel name is a variable, but the name is not set anywhere
3. remove the RETURN statements. They will end the program, but I think you want to keep trying until no errors are found.
4. I do not think you should set STA=0 until both checks are ok. Currently, it will exit if one is ok, but not the other.
5. perhaps it got lost here in the forum, but you should indent nested lines
6. the ELSE will only perform one statement. you need to enclose your ZEDSMSG and the SETMSG within a DO / END clause.
7. move ADDPOP outside of loop.
8. good practice to have REMPOP after your ADDPOP
9. on your DO WHILE, good practice to enclose the condition within parenthesis.
10. check return code from DISPLAY. user might have cancelled panel, in which case you should exit and not perform any field checking.
11. surprised if "DISPLAY PANEL (" works. there should not be a space there.
12. I do not think you need the labels (AGN_CHK, STE_CHK)
13. I think your short messages should be in mixed case.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF All times are GMT + 6 HoursGoto page Previous  1, 2
Page 2 of 2