wordfile for aspx with c# works perfectly except for...

wordfile for aspx with c# works perfectly except for...

4
NewbieNewbie
4

    Sep 27, 2005#1

    every thing works fine (note: <script runat="server"> must be replaced with <script runat="server" language="c#"> for highlighting and function list), except for that I have to remove original asp with vbscript section, because "aspx_lang" is not defined... a foolish reason, isn't it?
    Or, there is a way to improve?

    first, make sure your html file extents includes aspx:

    /L3"HTML" HTML_LANG Nocase Noquote Block Comment On = <!-- Block Comment Off = --> File Extensions = HTM HTML SHTML HTT HTX CFM JSP PHP PHTML ASP ASPX

    then, replace the L10 section (asp with vbscript section) with (tab must be replaced with a real tab character):

    /L10"ASPX" ASP_LANG Line Comment = // String Chars = "' Escape Char = \ Block Comment On = /* Block Comment Off = */ File Extensions =
    /Delimiters = ~!@%^&*()-+=|\/{}[]:;"'<> ,tab.?
    /Function String = "%[a-zA-Z_]*)[~;]"
    /Indent Strings = "{"
    /Unindent Strings = "}"
    /Open Brace Strings = "{" "(" "["
    /Close Brace Strings = "}" ")" "]"
    /Open Fold Strings = "{" "#region"
    /Close Fold Strings = "}" "#endregion"
    /C1"Keywords"
    as auto
    base break
    case catch const continue
    default do
    else event explicit extern
    false finally fixed for foreach
    goto
    if implicit in internal
    lock
    namespace null
    operator out override
    params private protected public
    readonly ref return
    sealed stackalloc static switch
    this throw true try
    unsafe using
    virtual void
    while
    /C2"C# Data Types"
    bool byte
    char class
    decimal delegate double
    enum
    float
    int interface
    long
    object
    sbyte short string struct
    uint ulong ushort
    /C3"C# Preprocessor Directives"
    #elif #endif #endregion #else #error
    #define
    #if
    #line
    #region
    #undef
    #warning
    /C4"Operators"
    +
    -
    *
    ?
    =
    // /
    %
    &
    >
    <
    ^
    !
    |
    :
    checked
    is
    new
    sizeof
    typeof
    unchecked
    /C5"Tags"
    <%
    %>
    /C6"Objects"
    Application
    Cache Cookies
    ObjectContext
    Form
    QueryString
    Request Response
    Server ServerVariables Session


    and also, I do wonder about why does ultraedit think the extent ".aspx" has something to do with "asp_lang"?

    totally magic!!

      Sep 29, 2005#2

      nobody could give me any help?

      1
      NewbieNewbie
      1

        ASPX single-quote comment highlighting

        Feb 12, 2006#3

        I've been wrestling with a way to highlight ONLY comments delimited by a single quote in my ASPX files. However, it always picks up a single quote that exists within a quoted string so that the remainder of the line is highlighted only as a comment. VERY frustrating, and I believe shouldn't be picked up.

        However, I got an idea. I often try to add more blocking to my comments, so I start with '*****, possibly even using this to make a box around header comments. So I changed the comment delimiter from a single quote to a single quote and asterisk ('*) This works GREAT!

        Related, I also like the function list, but it's difficult to get only what I want on the list. So I add the string fnlist="true" to lines I want to show up in the function list, and viola! They're there!

        If you happen to know of a way to ignore single-quotes inside a double-quote delimited string, please post a reply. I searched, but couldn't find anything.

        --Lebear

        6,684585
        Grand MasterGrand Master
        6,684585

          Re: ASPX single-quote comment highlighting

          Sep 07, 2006#4

          Lebear wrote:If you happen to know of a way to ignore single-quotes inside a double-quote delimited string, please post a reply. I searched, but couldn't find anything.
          In the language line for ASPX specify String Chars = ". Now only double quoted strings are highlighted as string.

          Further you have to specify the characters "*' as delimiters if not already done.

          Your special comment style with '* must not be changed.

          But if you want also strings with single quotes highlighted as string, highlight it with marker characters:

          /Marker Characters = "''"
          /C8"Single quoted strings"
          ''

          The color for the group "Single quoted strings" can be either set to the color of strings or you use an other color.
          Best regards from an UC/UE/UES for Windows user from Austria

          3
          NewbieNewbie
          3

            Apr 06, 2007#5