public static bool ClickThis(this Ranorex.Container item) { System.Threading.Thread.Sleep(200); item.Click(); System.Threading.Thread.Sleep(200); return(true); }
public static void ClickThis(this Ranorex.Container item) { try { item.Click(); Sleep(); } catch (Exception ex) { throw new Exception("Container Click Failed : " + ex.Message); } }
//********************************************************************** /// <summary> /// RightClick to given items in the comoponet like Container. /// </summary> public static void RightClick_Item(LxScriptItem item) { object objComponet = item.getComponent(); RepoItemInfo objComponetInfo = item.getComponentInfo(); Type objType = objComponet.GetType(); if (objType.Name.ToString() == "Container") { Ranorex.Container targetContainer = objComponetInfo.CreateAdapter <Ranorex.Container>(true); targetContainer.Click(System.Windows.Forms.MouseButtons.Right); // Mouse.ButtonDown(System.Windows.Forms.MouseButtons.Right); } }