Function strings for XML

Function strings for XML

1
NewbieNewbie
1

    Dec 01, 2005#1

    Hello,

    I have a special problem to exclude some function pattern.

    Valid functions:
    <attribute name="Font" type="string">
    <attribute name="Family" type="string">
    ...

    only
    <attribute name="Attribute" type="string">
    and
    <attribute name="Name" type="string">
    are invalid.

    My function strings won't exclude them.

    /L6"XML" Noquote HTML_LANG Block Comment On = <!-- Block Comment Off = --> File Extensions = XML XUL
    /Delimiters = ~@$%^&*()+=|\{};"'<> ,
    /Function String 1 = "<element name="
    /Function String 2 = "<attribute name="

    My first test
    /Function String 2 = "<attribute name=?[~N]"
    was possible for "Name" but all other "N...." like
    <attribute name="Number" type="string">
    will also be missing.

    Please help me! I am not a specialist for regExp.

    6,686585
    Grand MasterGrand Master
    6,686585

      Dec 04, 2005#2

      There is no real solution for your problem. It is not possible to find a string which does not contain a specific word. You can only use a set of find strings, which does include as much as possible.

      For example:

      /Function String = "<^{attribute^}^{element^} name="[B-MO-Z]*""
      /Function String 1 = "<^{attribute^}^{element^} name="N[~a]*""
      /Function String 2 = "<^{attribute^}^{element^} name="Na[~m]*""
      /Function String 3 = "<^{attribute^}^{element^} name="A[~t]*""
      /Function String 4 = "<^{attribute^}^{element^} name="At[~t]*""

      finds all which names do not start with "Nam" or "Att". Hopefully this is enough for you.
      Best regards from an UC/UE/UES for Windows user from Austria

      44
      Basic UserBasic User
      44

        Dec 07, 2005#3

        Hi All,

        I have the following function strings defined for XML:

        /Function String = "target*name="^([~"]+^)">"
        /Function String 1 = "<target name="^([~"]+^)""
        /Function String 2 = "taskdef*name="^([~"]+^)">"
        /Function String 3 = "<bean id="^([~"]+^)""


        The last one is meant for elements like this one:

        Code: Select all

        	<bean id="chiefExecutiveOfficer"
        		  class="..."
        		  singleton="...">
        	</bean>
        My problem is that in my function list I am seeing this:
        "chiefExecutiveOffice
        instead of this:
        chiefExecutiveOfficer

        Can anyone let me know what I am doing wrong?

        Thank you!

        Rob
        :)

        344
        MasterMaster
        344

          Dec 07, 2005#4

          Hi Rob

          I took exactly your example in my wordfile:

          Code: Select all

          /L20"TEST Wordfile" Escape Char = ^ Noquote File Extensions = TEST TST
          /Function String = "target*name="^([~"]+^)">"
          /Function String 1 = "<target name="^([~"]+^)""
          /Function String 2 = "taskdef*name="^([~"]+^)">"
          /Function String 3 = "<bean id="^([~"]+^)""
          /C1
          bean
          and this code:

          Code: Select all

          <bean id="chiefExecutiveOfficer1"
          class="..."
          singleton="...">
          </bean>
          
          
          <bean id="chiefExecutiveOfficer2"
          class="..."
          singleton="...">
          </bean>
          
          
          <bean id="chiefExecutiveOfficer3"
          class="..."
          singleton="...">
          </bean>
          was displayed properly in my function list, without " sign :?:

          chiefExecutiveOfficer1
          chiefExecutiveOfficer2
          chiefExecutiveOfficer3

          Check it out exactly like I did. Make a new language with only these settings. Is it correct then?

          I only can estimate here, sorry

          rds Bego
          Normally using all newest english version incl. each hotfix. Win 10 64 bit

          44
          Basic UserBasic User
          44

            Dec 08, 2005#5

            Well, that's strange - even when I made a new language out of it I get the same results!

            Rob
            :)
            UltraEdit - licensed for life!

            http://robertmarkbramprogrammer.blogspot.com

            344
            MasterMaster
            344

              Dec 08, 2005#6

              Which version? I use 11.20a
              Did you reduce the example to EXACTLY "my" source?

              rds Bego
              Normally using all newest english version incl. each hotfix. Win 10 64 bit

              6,686585
              Grand MasterGrand Master
              6,686585

                Dec 08, 2005#7

                Why do you not use the simple version?

                /Function String = "target*name="^(*^)">"
                /Function String 1 = "<target name="^(*^)""
                /Function String 2 = "taskdef*name="^(*^)">"
                /Function String 3 = "<bean id="^(*^)""
                Best regards from an UC/UE/UES for Windows user from Austria