Selenium/Editor: How to click on a cell for inline edit

Selenium/Editor: How to click on a cell for inline edit

amanaV36amanaV36 Posts: 20Questions: 9Answers: 0

Hi all,

i am currently trying to set up some frontend tests with selenium and can't get selenium to open an editor inline edit.

what i tried is:
1. Scriptexecuter with jQueryselector Click: executor.executeScript("$('#singleCompanyTable tr:first td:eq(12)').click();");
2. Click on WebElement via xPath
3. Also tried the DataTables cell-selector with a click call afterwards.

None of these works. Has anyone an idea how i get selenium to click on that cell?

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 63,516Questions: 1Answers: 10,472 Site admin
    Answer ✓

    If you run that code directly in your browser, does it work? The one thing that I notice is that tr:first is going to select from the table header. Try adding in the tbody selector before the tr:first.

    Regards,
    Allan

  • amanaV36amanaV36 Posts: 20Questions: 9Answers: 0

    Thanks, that totally helped. Anyway the xpath way wont work. just that you know.

This discussion has been closed.