View previous topic :: View next topic
|
Author |
Message |
Vishu
New User
Joined: 23 Mar 2009 Posts: 22 Location: Bangalore
|
|
|
|
I have a question regarding CICS.
Requirement:
1. There are around 6 different fields to be entered via the CICS screen
2. All of these are to be validated via CICS-COBOL logic.
3. If any one of these doesn't satisfy the set criteria send a
message "**" to the message field .
Issue:
The issue is that whenever the 3RD option occurs the valid data is still displayed on the screen but the programm is not considering that.
say : month:12 year:2009 amount:
Now as the amount field was empty. Hence the message was displayed.
Other details remain unedited but when I enter amount:2000
A message related to invalid month is displayed. Unfortunately I have to enter all the details again.
I want a solution to avoid this redundant work of entering all the details again and again.
Please let me know if i missed any details |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8696 Location: Dubuque, Iowa, USA
|
|
|
|
Your program logic is faulty. Your code needs to handle the data across maps and transactions. You have a couple of options:
1. save (TSQ, DFHCOMMAREA, etc) the valid values and flags as to which invalid values you need. Each time you receive the map you only need to grab the invalid values and validate them.
2. set the MDT on each field before sending the error message map, so every field comes back in the next RECEIVE MAP. If you do this, you need to clear the output map only before the first time it is sent. |
|
Back to top |
|
|
Mickeydusaor
Active User
Joined: 24 May 2006 Posts: 258 Location: Salem, Oregon
|
|
|
|
When you are editing fields on the map ypu really need to start with the last field on the screen and work backward to the top of the screen. As
stated you have to have all of your input fields set with the FSET attribute
to return the data back to the program, then you have to reedit all the
fields again. |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
Quote: |
then you have to reedit all the
fields again. |
re-edit or re-populate? |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Also, validating data from the bottom right to the top left of the screen makes it easy to highlight multiple errors, leaving the cursor on the "first" error field. |
|
Back to top |
|
|
Vishu
New User
Joined: 23 Mar 2009 Posts: 22 Location: Bangalore
|
|
|
|
Thanks all for your help.
I tried adding the option FSET in the map defination and it is working fine.
-----------------------------------------------------------------------------------
* I have one more query.
I am trying to pass an account no from one program to another .
I have used XCTL and have sucessfully moved the value to the next level .However, when I tried copying and using it , it doesn't seem to work
Code:
IF EIBCALEN > ZERO
MOVE DFHCOMMAREA TO WS-COMMAREA
MOVE WS-COMMAREA TO WS-CUST-ID
end-if.
later in the code when I am using WS-cust-id it shows "......."
STRING WS-CUST-ID DELIMITED BY SPACES
WS-MONTH DELIMITED BY SPACES
WS-YEAR DELIMITED BY SPACES
INTO WS-ADJ-NO.
I even tried using WS-COMMAREA directly in the string by commenting out the move option.
Please let me know if i missed any details |
|
Back to top |
|
|
Vishu
New User
Joined: 23 Mar 2009 Posts: 22 Location: Bangalore
|
|
|
|
* I have one more query.
sorry for bothering you .
Its working fine |
|
Back to top |
|
|
|