View previous topic :: View next topic |
Author |
Message |
ramu_mohan21 Beginner
Joined: 29 Jun 2004 Posts: 106 Topics: 41 Location: Bangalore, INDIA
|
Posted: Fri Jun 04, 2010 4:12 am Post subject: COBOL Indentation |
|
|
Hi All,
Do we have any tool which does COBOL Code Indentation. _________________ Best Regards,
----------------
Rammohan Pabba
Software Engineer |
|
Back to top |
|
|
dbzTHEdinosauer Supermod
Joined: 20 Oct 2006 Posts: 1411 Topics: 26 Location: germany
|
Posted: Fri Jun 04, 2010 5:11 am Post subject: |
|
|
this link has a couple of mainframe apps that will do what you want, but they are not free:
http://www.cobug.com/cobug/docs/editors0036.html
not a lot of stuff (nothing for free) for the mainframe.
lots of stuff for the pc. google.
I have written my own ISPF Edit Macros to accomplish this.
but I rarely type, usually copy & paste. _________________ Dick Brenholtz
American living in Varel, Germany |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12370 Topics: 75 Location: San Jose
|
Posted: Fri Jun 04, 2010 10:41 am Post subject: Re: COBOL Indentation |
|
|
ramu_mohan21 wrote: | Hi All,
Do we have any tool which does COBOL Code Indentation. |
what is code indentation? is it related to having pic clauses in 40th column ,paragraph names in column 8 and all the sql statements if any to start in col 12 ???
Kolusu |
|
Back to top |
|
|
papadi Supermod
Joined: 20 Oct 2009 Posts: 594 Topics: 1
|
Posted: Fri Jun 04, 2010 4:43 pm Post subject: |
|
|
Indentation makes the code to appear like an outline - indentation is by "level"
For Data Division something like: Code: |
01 some-stuff.
05 part-1 pic x(10).
05 part-2.
10 fld1 pic xx.
10 fld2 pic x(7). |
For Procedure Dividion: Code: |
my-para.
if something = 'AASSDD' and
something-else not = 'VALUE'
perform some-other-para
end-if |
And so on for readability. _________________ All the best,
di
Last edited by papadi on Mon Jun 07, 2010 1:08 am; edited 1 time in total |
|
Back to top |
|
|
hari_uss Beginner
Joined: 19 Dec 2002 Posts: 78 Topics: 6 Location: Trivandrum, India
|
|
Back to top |
|
|
Anuj Dhawan Intermediate
Joined: 19 Jul 2007 Posts: 298 Topics: 7 Location: Mumbai,India
|
Posted: Tue Jun 08, 2010 9:34 am Post subject: |
|
|
Why not just do it while writing the code? I never found it that tough... _________________ Regards,
Anuj |
|
Back to top |
|
|
hari_uss Beginner
Joined: 19 Dec 2002 Posts: 78 Topics: 6 Location: Trivandrum, India
|
Posted: Thu Jun 10, 2010 12:58 am Post subject: |
|
|
Not applicable for systems which are 20-30 years old. You can expect anything and everything there. |
|
Back to top |
|
|
misi01 Advanced
Joined: 02 Dec 2002 Posts: 627 Topics: 176 Location: Stockholm, Sweden
|
Posted: Thu Aug 12, 2010 3:57 am Post subject: |
|
|
I have code for the PC that is free. One "problem" you have on the m/f is the fact that if the code is written with multiple if/else/if/else etc etc, indenting the code would end up trying to write details "beyond" column 80.
The code I have indents evaluates/ifs/strings and indents as must as necessary - the point being that it's easy for you to then see which blocks of code belong to which verbs.
Send me a private note if it's of interest. |
|
Back to top |
|
|
|
|