Retrieving Text between Text in Selenium C#

前端 未结 6 1371
走了就别回头了
走了就别回头了 2020-12-19 06:38

I am facing problem in retrieving Subject title of a mail from Unread mails using Selenium webdriver-C#.

Here\'s the HTML code :

6条回答
  •  离开以前
    2020-12-19 07:03

    Using GetAttribute("textContent") instead of Text() did the trick for me.

    Driver.FindElement(By.CssSelector("ul.list span")).GetAttribute("textContent")
    

提交回复
热议问题