Drag and Drop in Silver light application

Ask general questions here.
bchandus
Posts: 1
Joined: Mon Jan 13, 2014 8:39 pm

Drag and Drop in Silver light application

Post by bchandus » Mon Jan 13, 2014 8:49 pm

Hi,

I am using AUT developed in silverlight.
I have problem in drag and drop of list item.

I am using below code:

Mouse.ButtonDown(System.Windows.Forms.MouseButtons.Left);
Delay.Milliseconds(20000);
Ranorex.Mouse.MoveTo(600 , 400);
Delay.Milliseconds(5000);
Mouse.ButtonUp(System.Windows.Forms.MouseButtons.Left);

with the above code mouse is moving but not carrying the item.

Can some one help please!!!

Thanks!!!

User avatar
mebner
Posts: 61
Joined: Tue Dec 17, 2013 6:42 pm

Re: Drag and Drop in Silver light application

Post by mebner » Wed Jan 15, 2014 3:00 pm

Hi,

Have you already tried to record the drag'n'drop actions?
If not, can you give it a try?

Regards,
Markus

User avatar
Aracknid
Posts: 342
Joined: Tue Aug 10, 2010 3:23 pm
Location: Toronto, Ontario, Canada

Re: Drag and Drop in Silver light application

Post by Aracknid » Thu Jan 16, 2014 10:11 pm

Not sure if this will help, but I've found with drag and drop, sometimes the moveto needs to be slowed down for the AUT to recognize that it has in fact been moved. Try moveto with a delay so that it takes 1 or 2 seconds to do the move. You might notice it picks up the drag at this point.

Aracknid.