View previous topic :: View next topic
|
Author |
Message |
Deepak Dash
New User
Joined: 03 Sep 2007 Posts: 16 Location: India
|
|
|
|
Hi All,
I have seen few examples in this forum how to TRIM leading and Trailing spaces for a string in COBOL. Just want to know if there is a way to do the both for a string with a simple logic.
ws-string1 pic X(30) value ' cobol book '.
what I need is only 'cobol book' in my output string.
Is there a way? Appriciate your help. |
|
Back to top |
|
|
Deepak Dash
New User
Joined: 03 Sep 2007 Posts: 16 Location: India
|
|
|
|
Or I want to ask this question in another way like, How do I count the number of words that i have in my string?
Thanks. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
At the top of the page is a link to "IBM Manuals". Near the top is the COBOL Language Reference. Look here for info about UNSTRING which will answer your question.
If you find something in the manual that is not clear, post what you found and your doubt - someone will be able to clarify. |
|
Back to top |
|
|
|