Community
    • Login

    Replace text that only contain specific characters

    Scheduled Pinned Locked Moved General Discussion
    replacetargetre
    3 Posts 2 Posters 247 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.
    • Sheraz AhmedS
      Sheraz Ahmed
      last edited by

      Hi All, I have text in following formats:

      ASP1618099.jpg
      ASP1618100.jpg
      ASP1618101.jpg

      and need to change them with:

      ASP1717099.jpg
      ASP1717100.jpg
      ASP1717101.jpg

      It can be replaced with simply but the problem is that the file has multiple entries with same name and only extension is change like:

      ASP1618099.png
      ASP1618099.png
      ASP1618099.png

      Now I only want to change text with the extension of .jpg and do not want to change text having extension .png.

      Alan KilbornA 1 Reply Last reply Reply Quote 0
      • Alan KilbornA
        Alan Kilborn @Sheraz Ahmed
        last edited by

        @Sheraz-Ahmed

        One way:

        Find: ^ASP1618(\d{3})(?=\.jpg)
        Repl: ASP1717${1}
        Search mode: Regular expression

        Sheraz AhmedS 1 Reply Last reply Reply Quote 1
        • Sheraz AhmedS
          Sheraz Ahmed @Alan Kilborn
          last edited by

          @Alan-Kilborn Excellent bro , it worked zabardast

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