Drag and Drop on Andoird

I am using the following code for drag and drop action on android but somehow the same code works on ios but not in android.
Our app is a hybrid app and I am performing drag and drop in native context .

I could see the action is being done by enabling coordinates in android device but the tile is not getting dragged and dropped

Please suggest

TouchAction action = new TouchAction((AndroidDriver) DriverManager.getDriver())
.longPress(
LongPressOptions.longPressOptions().withPosition(PointOption.point(tapX, tapY))
.withDuration(Duration.ofMillis(20000)))
.moveTo(PointOption.point(tapX1 - 5, tapY1)).release().perform();

Check https://www.youtube.com/watch?v=oAJ7jwMNFVU

you can see as well: http://appium.io/docs/en/commands/interactions/actions/
the example is exactly what you need. but still, it is better to see the video and understand it first.

@mykola-mokhnach : Thanks for the reply . I will have look into the video

@ido_oserovitz Thanks for the reply . Will try as per the code