In an XML WebResponse
I get a URL tag which has a link to a PDF file. Example of the URL value is: https://www.member-data.com/files/hb/c8955fc4d6160ec0fd87f4
You can use WebClient.DownloadData
, which has a default return value of a byte array. e.g.
byte[] bytes = myClient.DownloadData("https://www.member-data.com/files/hb/c8955fc4d6160ec0fd87f4879c6496d3.pdf");
Also, this assumes that you want the actual file in a byte array, not the content (text) of the PDF. That's a whole other ball of wax.