473,396 Members | 1,929 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

using email template asp.net

gdc
Hi,
I want to create a custamizable e-mail template which will contain place
holders to fill the data from teh database and i want to use these templates
to send mails.
How do i create these templates?.
How do i use the templaes to send mails in asp.net?
thanks
gdc
Nov 18 '05 #1
2 2112
Okay, well, to send an email, you create a message (string), and send it.
The email template can therefore be a text file with tokens to replace in
it. A token is a character sequence which is recognized by your software.
For example, you could put [First Name] anywhere you want a certain First
Name to appear. Then you can use the String.Replace() method to replace all
occurrences of a given token with another string.

To use them, just open them and read them into a string. Then replace the
tokens, add the string as a message to an email, and send it.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Big things are made up
of lots of little things.

"gdc" <ra***********@hotmail.com> wrote in message
news:Of**************@TK2MSFTNGP09.phx.gbl...
Hi,
I want to create a custamizable e-mail template which will contain place
holders to fill the data from teh database and i want to use these templates to send mails.
How do i create these templates?.
How do i use the templaes to send mails in asp.net?
thanks
gdc

Nov 18 '05 #2
Kevin covered the template aspect of your issue.

As for sending the email, you can use the System.Web.Mail class.
Here's more info:
http://msdn.microsoft.com/library/de...temWebMail.asp

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://Steve.Orr.net
Hire top-notch developers at http://www.able-consulting.com
"gdc" <ra***********@hotmail.com> wrote in message
news:Of**************@TK2MSFTNGP09.phx.gbl...
Hi,
I want to create a custamizable e-mail template which will contain place
holders to fill the data from teh database and i want to use these templates to send mails.
How do i create these templates?.
How do i use the templaes to send mails in asp.net?
thanks
gdc

Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Sam | last post by:
I would like to store html templates in a database. By using perl I would like to retrive the template ask the user to fill the template and store the whole file is template + the user data in a...
4
by: Anthony Gallagher | last post by:
I have a bunch of libraries compiled using VC++ 6.0, and I am trying to recompile one of our projects using VC++ .NET. I get all kind of linker errors (specially in STL calls). How do I get rid of...
2
by: Hans Merkl | last post by:
Hi, I am trying to use a user control as EditItemTemplate in a DataList. It loads fine but I can't figure out how to bind to the data of the DataList. Here is what I have got so far: ...
3
by: Grep J | last post by:
Hello, I'm using Visual Studio.NET 2003 and I'm wondering that is it possible to call XSL file's template to transform a XML file? I have following files. A XML file below <?xml...
8
by: Jimbo | last post by:
Hello I am currently designing an internal ordering system for IT equipment. I am designing it in ASP.NET (vb) using Visual Studio 2003 and using Microsoft SQL Server I have got the system...
3
by: bloc | last post by:
I am programming an interactive CV using xml, xslt and java script. The page consists of a header which contains links to various 'sections' on the xml cv, a left and right menu, and a central...
7
by: tthunder | last post by:
Hi @all, I have a trivial question, but I cannot find any answer :( <xsl:template match="note"> <b>Note:</b> </xsl:template> <xsl:template match="note"> <p><!-- CALL <xsl:template...
2
by: kennykenn | last post by:
Hi, Ive producd code to send an email after capturing info off a form,it works fine locally but when i put it live it doesnt work! the code is stopin at 'msg.send' any ideas, here the code! ...
3
by: valoh | last post by:
Hi, is this legal c++ code? template <typename BaseTstruct A { BaseT& this_() { return *static_cast<BaseT*>(this); } template <typename Tvoid Foo() { this_().Bar<T>(); } template...
8
by: moondaddy | last post by:
I'm posting code for a user control ( FunctionConnectorSelector) below which has 3 content controls in it. each content control uses a style from a resource dictionary merged into the app.xaml...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.