i have list with codes
in a test module I am trying to replace last digits of code by +1 using substitute function but i am getting result-
A1B1_1 ->A2B2_2 ----incorrect
A1B1_2 ->A1B1_3 ------correct
A1B1_3 ->A1B1_4------correct
A1B2_1 ->A2B2_2 -----incorrect
A1B2_2 ->A1B3_3 -----incorrect
A1B2_3 ->A1B2_4------correct
first, i am extracting number after "_" then incrementing it by +1-> incremented value line item
substitute function--> substitute(code line item, logic to find character after"_" , incremented value line item)
please suggest approach to address this ....