Saturday, April 13, 2013

UltraEdit -- Syntax Highlighting not Working (How to fix)

Just a quick post here, if for no other reason so I can find it later myself.

With the last few versions of UltraEdit (up to v19 as of this writing) on my home machine (but not another machine I use UltraEdit on daily), my Coldfusion files would not correctly highlight upon opening.

There were two symptoms:
1. CFM files would highlight, but not CFC files.
2. The CFM file highlighting seemed "off" somehow.

Turns out the two symptoms had two causes:
1. The "cfm" file extension was associated with the HTML wordfile
2.  The line terminators were wrong on the Coldfusion wordfile.

Steps to corret:
1.  Removed the CFM extension from the HTML wordfile.
2.  On the Coldfusion wordfile, which did have the CFM and CFC extensions, I had to convert the file.

On the Coldfusion wordfile, after opening, I could see "UNIX" in the status bar:

As of UltraEdit v19, you change this by choosing:
    File > Conversions > Unix/Mac to DOS

You get a dialog about "can't undo", just choose "OK".

I had a CFC file open in another editor tab.  As soon as I saved the converted Wordfile, it automatically picked up the syntax highlighting.  Yay.

I found the original information on how to correct here, but it mentions hitting F12, but that might be old.  Use the steps above with "Conversion" to properly correct.
http://www.ultraedit.com/support/tutorials_power_tips/ultraedit/add_a_wordfile.html

- WIll Belden
April 13, 2013