Where to store email templates

Viewed 8712

I have an asp.net web application, which sends several emails to users during the signup procedure. Right now I have them inline with the code, but I would like to hold them in a central location where I can edit them without going in to VS.

What would be the best place/format to store these HTML templates?

6 Answers

Hope you were sorted, this is what I found and thought was easier.

  1. Open properties of your project.
  2. Go to the resource. Under resource 'Add Resource' => 'Add Existing File'

Then you can just access it like this.

var html = Resources.YourFileName;

Remember to add using

using YourProject.Properties;
Related