Community
    • Login

    How to replace any text between some text without specifics

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    3 Posts 2 Posters 62 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • th3lifeoftorchT
      th3lifeoftorch
      last edited by

      So I am editing a mod for a game called Star Wars empire at war on pc. I need help understanding how to replace text between text all at once
      (Ex.)I want to replace all <Tactical_Build_Time_Seconds>10</Tactical_Build_Time_Seconds> the ten in the middle I want to replace to a 1. However here is the issue. A lot of files have different numbers like <Tactical_Build_Time_Seconds>3.75</Tactical_Build_Time_Seconds> and <Tactical_Build_Time_Seconds>75</Tactical_Build_Time_Seconds> so how do I go about changing all of the numbers between all of the <Tactical_Build_Time_Seconds></Tactical_Build_Time_Seconds> at once? please and thank you.

      PeterJonesP 1 Reply Last reply Reply Quote 0
      • PeterJonesP
        PeterJones @th3lifeoftorch
        last edited by PeterJones

        @th3lifeoftorch ,

        Our FAQ: Generic Regular Expression (regex) Formula page has links to replacing in a specific zone of text, and the related replacing a complete hierarchy between an opening XML/HTML tag and its corresponding closing tag (which would help if you had nested XML tags, though I don’t think you do). Most likely, the “zone of text” formula will give you what you need.

        Though, really, with as simple as yours is, the regular expression search <Tactical_Build_Time_Seconds>\d*\.?\d*</Tactical_Build_Time_Seconds> should be enough for the FIND WHAT

        th3lifeoftorchT 1 Reply Last reply Reply Quote 3
        • th3lifeoftorchT
          th3lifeoftorch @PeterJones
          last edited by

          @PeterJones Very much appreciate this, you saved me a lot of time

          1 Reply Last reply Reply Quote 0
          • First post
            Last post
          The Community of users of the Notepad++ text editor.
          Powered by NodeBB | Contributors