コード例 #1
0
        /// <summary>
        ///
        /// </summary>
        public static HtmlElement GetElementInCollection(this WebBrowser wb, HtmlElementCollection elCol, string value, ElementText elText = ElementText.InnerText)
        {
            if (wb.IsNull() ||
                elCol.IsNull())
            {
                return(null);
            }

            foreach (HtmlElement elItem in elCol)
            {
                if (wb.GetData(elItem, elText).Contains(value))
                {
                    return(elItem);
                }
            }

            return(null);
        }