asked 1 year ago
Drag and drop:
To drag and drop the element on a web page, the selenium web driver provides an Action class.
We can use the drag and drop method of Actions class and pass the parameters as the first element(Sourcelocator) "From" and the second element(Destinationlocator) "To".
Navigate to https://www.qafeast.com/demo,click the drag and drop tab.
Press F12 in the keyboard and inspect drag and drop.
Syntax:
(new Actions(driver)).dragAndDrop(from, to).perform();