Guys,
I'm trying to change a place holder in an external HTML template then email as a body.
I can get this working fine but I'm struggling to get it to read an external html file from url with streamreader.
I'm assuming I would need to use WebRequest instead of streamreader to get the remote html file?
below is my code:
using (StreamReader reader = new StreamReader(http://mytemplate))
{
body = reader.ReadToEnd();
}
body = body.Replace("{CompanyName}", companynameTextBox.Text);

Manas MohapatraRank #182 · 13.2K reputationPosted Sep 24, 2015, 10:23 AM EDT
mike DelvottiRank #7,298 · 244 reputationPosted Sep 25, 2015, 3:50 AM EDT
Hi, Thank you - yes I got it working with parts of your code.
Manas MohapatraRank #182 · 13.2K reputationPosted Sep 25, 2015, 4:04 AM EDT