Highlight text beginning with comma, dollar, etc.

Highlight text beginning with comma, dollar, etc.

3
NewbieNewbie
3

    Mar 31, 2006#1

    I apologize if this has been covered, but I couldn't find it anywhere.

    How can I get any string beginning with the same text (comma, percent, etc.) to be highlighted?

    Thanks for your help.

    119
    Power UserPower User
    119

      Mar 31, 2006#2

      First, remove those characters from the Delimeters section in the syntax hightlighting for that file type. Then create a color section for them using ** to match leading characters. e.g. In Perl, all variables start with $, @, or %. I have the following in the Perl section of my wordfile:

      Code: Select all

      /C5"Variables"
      ** $ @ %

      3
      NewbieNewbie
      3

        Mar 31, 2006#3

        Thanks, but that didn't work. I'm trying to do this in SAS programs, so that comma9. or percent5. would be highlighted (I'd be happy with just the comma or percent part of the format).

        6,686585
        Grand MasterGrand Master
        6,686585

          Apr 01, 2006#4

          Remove the point . from the /Delimiters= list and add

          /C8"Substrings"
          ** comma9.
          ** percent5.

          Or second suggestion: After removing the point character from the /Delimiters= list add the figures 0123456789 to the delimiters list and add

          /C8"Substrings"
          ** .
          Best regards from an UC/UE/UES for Windows user from Austria