Pesudo conversation logic



Support for CICS/ESA, CICS/TS & Transaction Gateway, CICS Configuration Manager and CICS Performance Analyzer

Pesudo conversation logic

Postby kandrepavan » Thu Aug 02, 2012 10:20 am

Hi all,

PLease can any one say what is the error in this code.
When the Transcation is initiated the Map is thrown on to the screen and then later it is always entering to
Return TRansid() commarea( ) command.
The Code is:

01 WS-COMMAREA.
05 WS-I-CH PIC 9(1).
88 C01-CH-PENQ VALUE 1.
88 C02-CH-POAPPLY VALUE 2.
88 C03-CH-PEDIT VALUE 3.
88 C04-CH-PCANCEL VALUE 4.

LINKAGE SECTION.
01 DFHCOMMAREA.
05 LS-CHOICE PIC 9(1).

***************************************************************
* PSEDUO CONVERSATION LOGIC.
PROCEDURE DIVISION.
*
0000-MAIN-PARA.

EVALUATE TRUE

WHEN EIBCALEN = 00
MOVE LOW-VALUES TO PHOMEMPO
MOVE -1 TO HACTL
SET WS-A-HOME-C TO TRUE ----------------- in the mapsend-para i ma evaluating which map need to be send
PERFORM 2000-MAPSEND-PARA
THRU 2000-MAPSEND-PARA-EXIT
MOVE 1 TO WS-I-CH

WHEN WS-COMMAREA= 1
PERFORM 3000-RECEIVE-PARA
THRU 3000-RECEIVE-PARA-EXIT

END-EVALUATE.

EXEC CICS
RETURN TRANSID('TAA3') COMMAREA(WS-COMMAREA)
END-EXEC.


0000-MAIN-PARA-EXIT. EXIT.


2000-mapsend-para.
2000-mapsend-para-exit.
3000-receive-para.
3000-receive-para-exit.
The control is not at all gng to Receive para

Thanx and regards
pavan
kandrepavan
 
Posts: 35
Joined: Wed Mar 21, 2012 11:03 am
Has thanked: 0 time
Been thanked: 1 time

Re: Pesudo conversation logic

 

Re: Pesudo conversation logic

Postby kandrepavan » Thu Aug 02, 2012 10:48 am

WHEN WS-COMMAREA= 1

Here i tried with
WHEN EIBCALEN = 1 then also same problem
kandrepavan
 
Posts: 35
Joined: Wed Mar 21, 2012 11:03 am
Has thanked: 0 time
Been thanked: 1 time

Re: Pesudo conversation logic

Postby NicC » Thu Aug 02, 2012 11:41 am

You do not 'throw' maps onto screens - one or other may break. You send the map to the screen or the screen displays the map. You only throw things in curly-whirly languages like java and c++. Also, when posting code, use the code tags to make it align and read-able.

Now, what was the value in WS-COMMAREA when you displayed it?
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2531
Joined: Sun Jul 04, 2010 12:13 am
Location: Down on the pig farm
Has thanked: 4 times
Been thanked: 88 times

Re: Pesudo conversation logic

Postby mongan » Thu Aug 02, 2012 12:44 pm

I assume that the first use of the program is also from the same transaction, or is it triggered from XCTL?

The first use of your program will have an EIBCALEN of 0, WS will not be populated.
The second use of your programm will have an EIBCALEN of 1, WS will not be populated (it has random characters in it unless you initialize it or move something to it), LS-CHOICE in the DFHCOMMAREA should have the value of 1.
User avatar
mongan
 
Posts: 212
Joined: Tue Jan 11, 2011 8:32 pm
Has thanked: 1 time
Been thanked: 5 times

Re: Pesudo conversation logic

Postby Monitor » Thu Aug 02, 2012 3:27 pm

Pls post the whole code using code-tags and we will be able to tell you whats wrong with your logic.
Monitor
 
Posts: 98
Joined: Wed Jan 18, 2012 8:59 pm
Has thanked: 0 time
Been thanked: 7 times

Re: Pesudo conversation logic

Postby Monitor » Thu Aug 02, 2012 3:39 pm

You are testing
WHEN WS-COMMAREA= 1

which is a dataelement in your Working-Storage.
You should test the value in the DFHCOMMAREa like this:
When LS-CHOICE = 1

You have prepared for 88´s in the Ws. Copy those to the commarea like this:
01 DFHCOMMAREA.
   05 LS-I-CH PIC 9(1).
      88 C01-CH-PENQ VALUE 1.
      88 C02-CH-POAPPLY VALUE 2.
      88 C03-CH-PEDIT VALUE 3.
      88 C04-CH-PCANCEL VALUE 4.

The you can say:
When C01-CH-PENQ

Pls note that you have to take care of the naming-problem that now will appear, becasue the 88´are not unique.
In the future, post your code using the code-tags.
Monitor
 
Posts: 98
Joined: Wed Jan 18, 2012 8:59 pm
Has thanked: 0 time
Been thanked: 7 times


Return to CICS

 


  • Related topics
    Replies
    Views
    Last post