I'm working on a project when I need to copy the innerHTML of a div and send it to a txt file in C#. While I can get the innerHTML of the entire page through this code:
private void button3_Click(object sender, EventArgs e)
{
using (WebClient client = new WebClient())
{
string htmlCode = client.DownloadString("youtube.com");
textBox1.Text = htmlCode;
}
}
What do I need to do to get the innerHTML of a specific div? Thanks!