I'm using webbrowser control .I want to save the current web page using (save,save as)and with multiple save file types(web archive,complete,HTML single file,text)exactly like IE.
any help guys
Printable View
I'm using webbrowser control .I want to save the current web page using (save,save as)and with multiple save file types(web archive,complete,HTML single file,text)exactly like IE.
any help guys
SaveFileDialog can do that,if so how plz??
Thanx in advance
You can use the System.Net namespace to get the webpage into a stream and then use a BinaryWriter with a FileStream (both from System.Io) to do this. I might have an example at work for you. Need to sleep now though....... post to tell me if you need an example and I'll try to give it in the morning (ie in 10 hours).
but if he's using webbrowser control that'd suck because he would have to download the web page all over again...
to get the source code of the webpage open do this:
dim mystring as string
mystring = webbrowser1.document.body.innerhtml
Correct, I agree that the first part was something that popped out of me without thinking it all through. Doesn't leave out the use of a FileStream to write to and a StreamWriter to do the job though, does it? :)
I couldn't reply your post athley last days .Ok , it's kind of you if you sent me that example?
darn, now I'm free for Christmas weekend. :P
hmmm, I'll try to dig something up. :)
I'm sorry Athley , I thought it's ready.;)
Yea it is, but its at work, and I'm on holiday :P
never mind;)