/// <summary> /// Selects the list item from a listbox, dropdown box based on the value. /// </summary> /// <param name="selectLocator">The select locator.</param> /// <param name="value">The value to be selected.</param> /// <param name="type">Type of locator</param> /// <param name="useSitemapId">By default element id will be picked from sitemaps, false to use the control Id directly</param> /// <param name="sourceType">Default mentions the element is of Id type</param> public void SelectByValue(string controlId, string value, bool useSitemapId = true, FindType sourceType = FindType.ById) { string locator = useSitemapId == true?_siteMapData.GetLocator(controlId, out sourceType) : controlId; _client.SelectByValue(locator, value, sourceType); }