Okay, I am working on a profile which contains many IDs for objects in general.
All the initial code had to be edited so more functions could be added, and it's about 1200 ID's I would have to manually edit one by one. So I thought maybe Notepad++ could use RegEx functions to do the whole editing for me.
The problem however, is that I need to retrieve the ID from line 2 which is whitin quotes and then put this ID in line 1 which has to be between parentheses. This step will be repeated multiple times so instead of being line 2 and line 1, the next set will be line 4 and 3 and so on.
Example:
Line 1: < InbagCount(11111) />
Line 2: < ItemID="12345" />
Line 3: < InbagCount(11111) />
Line 4: < ItemID="543" />
Now, I need to replace all the 11111 with the next line's ItemID.
this is the code I've been using which matches the text inside ItemID=""
(?<=ItemID=")(?:\\.|[^"\\])*(?=")
It works to find them but when I click the Replace button this is what happens:
InbagCount(?<=ItemID="?:\.|[^"\]*?=")
Maybe Notepad++ is not the tool for this job.
Does anyone have an idea of what I can use?
Thanks in advance, I would be very appreciated if you can help me :)