Announcement

Collapse
No announcement yet.

Grammar - how to ignore it

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Grammar - how to ignore it

    Hi sir,

    Click image for larger version  Name:	image.png Views:	0 Size:	2.8 KB ID:	90017​​
    I'm trying to ignore the digit dd.ddd for the Amps but I could not get luck, I have tried below grammar and others but always failed(could not let red digit turn to blue one):

    Click image for larger version  Name:	image.png Views:	0 Size:	19.8 KB ID:	90016

    Please guide me how the grammar can achieve my desired output, thank you.
    Attached Files

  • #2
    Hello,

    That reg ex actually looks ok, but string is normally Important by default. I would suggest giving this a custom name like "Amps" and then going to the Text Compare's Session menu -> Session Settings, Importance tab, and uncheck "Amps". This can be either "for the current view only" in the bottom dropdown or "also update session defaults".

    Hence the suggestion to alter the Element name. If you uncheck string and update defaults, then all strings across all file formats (HTML's "strings", etc) will then be Unimportant, too.
    http://www.scootersoftware.com/suppo..._unimportantv3
    Aaron P Scooter Software

    Comment


    • #3
      Oh, one minor update to your RegEx, if I can see your screenshot correctly. You should update:
      . = any character
      to
      \. = literal .
      if you want it to be more specific.
      Aaron P Scooter Software

      Comment


      • #4
        Hi Aaron,

        Sorry, I think the original question is wrong, the question is that how I can ignore both Amps and Volts.

        Click image for larger version

Name:	image.png
Views:	50
Size:	3.5 KB
ID:	90035
        If I add below one then the Amps can be ignored.

        (\d|\d\d).\d*\s*[|]\sAmps

        The same, if I change the 'Amps' to 'Volts', then the Volts can be ignore.

        (\d|\d\d).\d*\s*[|]\sVolts

        But, if I add both rules in grammar, the first priority will be applied, but the later one will not, for example as below, it will aplply to Amps, but Volts not to be ignored.

        (\d|\d\d).\d*\s*[|]\sAmps
        (\d|\d\d).\d*\s*[|]\sVolts

        So, please advise how to set it to apply both conditions, thanks.

        Jacky

        Comment


        • #5
          Hello,

          What custom file format names are you using? Whenever you create a new Element in the file format, it defaults to Important, so you have to make sure both custom names are unchecked in the Importance tab.

          When you click the cursor into the text (say, between the | and the V or A of the words), the bottom status bar should reveal the Element name the cursor resides in. What does it show?

          If you are still having trouble, you can also email in sample files, a full screen screenshot, and your current Support package that contains your settings (Help menu -> Support; Export), and I can reproduce what you are seeing in the screenshot for more specific instructions. If emailing into [email protected], please include a link to this forum thread for our reference.
          Aaron P Scooter Software

          Comment


          • #6
            Hi Aaron,

            Have just sent a mail with support files and example files to [email protected]​, please check it, thanks!

            Jacky

            Comment


            • #7
              Hello,

              To follow up here as well, with your sample files I was able to select your element with Volts, use the Clone element button, made a slight modification to rename Volts to Amps, and the element was then unimportant like you expected, and both sets of data were then blue/unimportant differences.
              Aaron P Scooter Software

              Comment


              • #8
                Originally posted by Aaron View Post
                Hello,

                To follow up here as well, with your sample files I was able to select your element with Volts, use the Clone element button, made a slight modification to rename Volts to Amps, and the element was then unimportant like you expected, and both sets of data were then blue/unimportant differences.
                Thank you very much, I found the problem was caused by the element name, I add it with string which is the s with lowercase, but it worked after I change the s to S with uppercase (String).

                My question is resolved.

                Comment

                Working...
                X