If you don't close it the stream will still contain the data that is in the postarray, with the "current position" at the end of the stream. If you want to read it, you'd need to reset the position. Then again, why would you read from the stream the data that you just wrote to it?
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
I don't want to read from what I wrote. The data I wrote in not in the stream but in postArray.
MydataStream.Write(postArray, 0, postArray.Length)
From the MS example Steam = MyWebClient.OpenWrite(... It was my assumption that this was be a response like it is if it were an OpenRead (which does work).
The MSDN sample doesn't show it processing a response.
I had to get the target server people to trace what they were getting and tell me what was wrong. Eventually found out that I had to add the below ContentType and remove the leading "?" from the postData.
None of the debugging in the .net code was of any help since without the below the postdata was being sent as 1 field and they were not returning anything if the postdata was invalid.
I already explained the two options that are available to you, in my previous answer: use a PDF printer, or write the code yourself using a third party library (or you could do it the hard way). I can only assume that you do not understand PDF format, so I suggest you go to http://www.adobe.com/devnet/pdf.html[^] and read the documentation.
I have a form, with a web browser object on it, in which when the document is complete, the event fires and processes the HTML on the form.
If the web page has child forms on it, then I call another automation class, in which I remove the original handler for the web browser object, and switch to the new handler in the child automation class.
Now I'm done processing child page forms, and I call the next parent form
I'm trying to figure out how to reload the original event handler that I unloaded earlier, so I can continue to process more parent pages.
1. frm_download_data - the form with the web browser object
There's no event handler
2. html_automation_reseller_product_page.vb - Parent Pages, Original Web Browser Document Handler
Public Sub WebBrowser_Page_DocumentCompleted(sender As Object, e As WebBrowserDocumentCompletedEventArgs)
3. html_automation_reseller_product_child.vb - Child Pages, New Web Browser Document Handler
Protected Sub WebBrowser_PageChild_DocumentCompleted(sender As Object, e As WebBrowserDocumentCompletedEventArgs)
//Swing back to the parent pages
AddHandler g_WB.DocumentCompleted, AddressOf html_automation_reseller_product_page.WebBrowser_Page_DocumentCompleted//Shared Object?
g_DDL.Text = g_complete_Url
Now I want to return back to 2, and reload the Web Browser Handler.
I wonder if I planned this out poorly, and painted myself into a corner here.
I don't' want to make the Handler on 2 shared.
Last Visit: 31-Dec-99 19:00 Last Update: 21-Dec-14 8:33