2
Answers

Webbrowser Document.Text strange errors

Jon

Jon

15y
7.4k
1
this small line of code is giving me so much trouble:
textbox1.Text = webBrowser1.DocumentText;

It has about a 50% chance of working and i havnt even changed anything when it stops working!
The error i get is: File not found referring to a String

in debug looking at locals it was Webbrowser1.DocumentText Exception: File not found  type: string

All i want to happen is for the html from the current page in the browser to be put in my textbox.
This will be done many times by the way, maybe every 4 seconds.

I would give you the exact text of the error but its working fine right now!
Its really annoying because i cant attempt to fix it unless its broken.


EDIT: It broke again, did not change anything, just opened the project.
Error:   DocumentText    'this.webBrowser1.DocumentText' threw an exception of type 'System.IO.FileNotFoundException'    string {System.IO.FileNotFoundException}



Answers (2)