|
I found some solutions to read text web document
using StreamReader and ReadToEnd, but the solutions does not work with binary data
(pdf and doc documents, gif and jpeg images). Next function reads binary document
from URL using HttpWebRequest and returns the document as byte()
See alsofor 'HttpWebRequest and binary document, VB.Net code' article Copyright and use this code
The source code on this page and other samples at https://www.motobit.com/tips/
are a free code, you can use it as you want: copy it, modify it, use it in your products, ...
If you use this code, please:
1. Leave the author note in the source.
or
2. Link this sample from you page.
<A Href="https://www.motobit.com/tips/detpg_vbnet-binary-get-url/" Title="Short function to read binary data (pdf, gif) from URL using HttpWebRequest, ResponseStream and temporary binary memory stream." >HttpWebRequest and binary document, VB.Net code</A> Do you like it? Rate me on LinkedIn |
© 1996 - 2019 Antonin Foller, Motobit Software | About, Contacts