0

I wonder if more than two inputs can be filled in one text with textWithLabel method.

enter image description here

bot.textWithLabel("Resolution", 0).setText("800"); bot.textWithLabel("Resolution", 1).setText("600");

above is not working.

give me the solution. thanks in advance.

1 Answers1

0

Actually.

textWithLabel("Resolution", index) is working fine.

but why it failed is that numeric verifylistener was wrongdoing. original source had bug. and i fixed.

I was confirmed that Original source was fine but it wasn't.

SWTBOT is cool open source project for automating GUI test.

thanks.

org numeric verify source

private void chkDigit(VerifyEvent e) {
    if (!Character.isDigit(e.character)) {
        e.doit = false;
    }
}

changed 
private void chkDigit(VerifyEvent e) {
    e.doit = NumberUtils.isNumber(e.text);
}