Created On:  05 February 2012

Problem:

Our COBOL source files use the extension ".cl2".

When I bring these files into Visual COBOL Eclipse and edit them they do not appear with the same editor colorization or background parsing as when I use the a standard extension like .cbl.

Is there a way to modify Eclipse so that it recognizes my extension as being a COBOL source program?

Resolution:

Here are the instructions for adding a new extension as a COBOL content type in Eclipse so that your files are recognised as COBOL programs throughout the IDE:  (in this example we are adding .cl2)

1. Navigate to Window->Preferences
2. Navigate to General->Content Types
3. Open up Text and then Micro Focus COBOL Project Types
4. Click on COBOL Source File
5. You should now see the default list of file extensions we recognize for the COBOL source content type
6. Click the Add... button
7. Enter the extension you desire (in this case, *.cl2)
8. Click OK, OK. 

Any file with the .cl2 extension will now be treated as a COBOL type.