how to connect 2 string into one.



Support for OS/VS COBOL, VS COBOL II, COBOL for OS/390 & VM and Enterprise COBOL for z/OS

how to connect 2 string into one.

Postby leon » Sat Dec 06, 2008 1:53 am

hi,

can anybody tell me how to connect 2 string in COBOL, thx.

ex:
05 WS-TEXT PIC X(15) VALUE " The total count is: ".
05 ws-count pic 9(5) value 0.

05 WS-result-message PIC x(20) value space.
can i use the idea or you have better idea, thax.

move ws-text TO WS-result-message(1:15)

MOVE WS-count TO WS-result-message(16:)
leon
 
Posts: 40
Joined: Tue Nov 25, 2008 7:39 pm
Has thanked: 0 time
Been thanked: 0 time

Re: how to connect 2 string into one.

Postby gurzi » Sat Dec 06, 2008 2:14 am

STRING WS-TEXT WS-COUNT INTO XPTO DELIMITED BY SIZE

TEST PLEASE
gurzi
 
Posts: 4
Joined: Sat Dec 06, 2008 1:49 am
Has thanked: 0 time
Been thanked: 0 time

Re: how to connect 2 string into one.

Postby leon » Tue Dec 09, 2008 2:08 am

thank you very much!
leon
 
Posts: 40
Joined: Tue Nov 25, 2008 7:39 pm
Has thanked: 0 time
Been thanked: 0 time


Return to IBM Cobol

 


  • Related topics
    Replies
    Views
    Last post