Hello guys,
As would extract only the code for the numeric part (after the first and before the second colhete), and the number can vary from 1 to 6 digits for example?
I am using this function:
String nomeBotao = cp5_04.window(this).getMouseOverList();
println(nomeBotao);
The reason you need this is that I may control in a single event, several buttons without worrying about the name of each ...
example:
if (cp5_04.isMouseOver(cp5_04.getController("btn1"))){
if (tempoAutClick) verificaTempo();
} else if (cp5_04.isMouseOver(cp5_04.getController("btn2"))){
if (tempoAutClick) verificaTempo();
} else {
clicouMouse = false;
savedTime = millis();
}
Would look like this:
if (cp5_04.isMouseOver(cp5_04.getController(nomeBotao))){
if (tempoAutClick) verificaTempo();
} else {
clicouMouse = false;
savedTime = millis();
}
I hope you understand.
Thank you.