I am developing UI automation for my control. The below code working fine in VS2012.
MyControl.PointToClient(p);
But this code not working in VS2013. It was throws an following exception
Also i have used the below code to Invoke the control
public new Point PointToClient(Point p)
{
if (MyControl.InvokeRequired)
{
pointToClientCallBack ptcb = new pointToClientCallBack(PointToClient);
GetWindow().Invoke(ptcb, new object[] { p });
}
return MyControl.PointToClient(p);
}
delegate Point pointToClientCallBack(Point p);after i invoked my control, InvokeRequired property is in true.
So, can you please suggest me the right way to solve this problem.
Thanks,
Mohanraj G.