i have this kind of string:
COMC1.20DI
I need to extract, in this case "1.20", but number can have decimals or not. How can I do it? I also need to get the start and end position of the number.
For starting position, I found
value.search(/\d/);
But I can't get any code to work for getting the last position of the number.
How can I do this?