What is sounds Like you are trying to do is, take a predetermined list of websites that are listed in a text documenton on the local file system.
(Need to determine How they are listed in the Text document,1 per line,or as a Delimited file of some sort)
Then Using a Web browser control Open each web page.
(parse a line of the Text file for the Address then use the Web browser control to open and view the page or use some version of a For each loop to add the Addresses to a Collection Or list Then Use that List for the web Addresses to open)
(Make sure the Page has Loaded Completly)
And then Take A screen shot Of what the Browser Control Is Displaying.
Then Save the Screen shot to the Local File system.
For each Site on the List.
But what the Code Listed Above Looks like it is doing is.
Open File, read all lines, upload as 1 big "String".
Can't tell from the code Where it is supposed to "Upload" to.
Then It Triggers a Event Handler For if the Document Is loaded. Not clear in posted code on how the event handler works.
And Supposed to take the said Screenshot.
Also you are catching The Error for Navigate Content And should probly Be giving feedback about the Error but appears to be silently ignoring the URI Format Error
Best I can tell in order to do what you want then you will need allot more code.
Not sure if this will help any or not
WebBrowser.Document Property
http://msdn.microsoft.com/en-us/library/system.windows.forms.webbrowser.document.aspx?cs-save-lang=1&cs-lang=csharp#code-snippet-2[
^]
Updated:
Link to Webbrowser Sample
http://msdn.microsoft.com/en-us/library/3tst62z1(v=vs.90).aspx[
^]
Visual Studio Samples Page.
http://code.msdn.microsoft.com/vstudio/site/search?query=Webbrowser&f%5B1%5D.Value=Webbrowser&f%5B1%5D.Type=SearchText&f%5B0%5D.Value=9.0&f%5B0%5D.Type=VisualStudioVersion&f%5B0%5D.Text=Visual%20Studio%202008&ac=3[
^]
Hope this help some.