/// <summary> /// Click the ASP.NET control element (usually a Button instance) with the given clientID and wait for the response /// when expectPostBack is true. /// </summary> /// <param name="clientId">HTML id attribute of the element to click on</param> /// <param name="expectPostBack">Whether to expect a server request from the click</param> /// <param name="expectedStatusCode">Expected StatusCode of the response</param> /// <param name="delay">Optional delay time in milliseconds before clicking the element</param> /// <param name="pause">Optional pause time in milliseconds after IE claims DocumentComplete</param> public static void ClickID(this IIE inst, string clientId, bool expectPostBack = true, int expectedStatusCode = 200, int delay = 0, int pause = 0) { var button = GetHTMLElement(inst, clientId); IEExtensionBase.Click(button, expectPostBack, expectedStatusCode, delay, pause); }
/// <summary> /// Click the ASP.NET control element (usually a Button instance) at the given path and wait for the response /// when expectPostBack is true. /// </summary> /// <param name="path">Member name path to the control starting at the main control</param> /// <param name="expectPostBack">Whether to expect a server request from the click</param> /// <param name="expectedStatusCode">Expected StatusCofe of the response</param> /// <param name="delay">Optional delay time in milliseconds before clicking the element</param> /// <param name="pause">Optional pause time in milliseconds after IE claims DocumentComplete</param> public static void Click(this IIE inst, string path, bool expectPostBack = true, int expectedStatusCode = 200, int delay = 0, int pause = 0) { var button = GetHTMLElement(inst, ControlRootExtension.GetRoot(), path); IEExtensionBase.Click(button, expectPostBack, expectedStatusCode, delay, pause); }