Find number betwen commans
-
I have this file:
[p2,115,0,4,] Steel Drums
[p2,116,0,4,] Woodblock
[p2,117,0,4,] Taiko
[p2,119,10,4,] Sine Perc.
[p2,118,0,4,] Melo. Tom 1
[p2,118,18,4,] Jungle SDHow to subtract “1” to the first value between comans
,115,
,116,
,117,
,118,
,118,
etcThanks
-
You would have to script a solution to that.
A similar discussion that would show you how to do it is HERE.In your case your “find” expression could be:
p2,(\d+),and you could replace with'p2,' + str(int(m.group(1)) - 1) + ','or something close to that; there are a few different ways to write these expressions.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login