Send captured form to an email recipient ASP.Net C#

Joined
Apr 8, 2008
Messages
1
Reaction score
0
I'm trying to take a web captured form and send it to the mail recipient with its values! The body of the email it's in HTML format. I get the form but without captured values, this is the code i use to achieve this

private string getPage()
{
string strPage = "";
Uri MyUrl = Request.Url;

WebRequest req = WebRequest.Create(MyUrl.AbsoluteUri);

StreamReader stream = new StreamReader(req.GetResponse().GetResponseStream());

System.Text.StringBuilder sb = new System.Text.StringBuilder();
string strLine;

while ((strLine = stream.ReadLine()) != null)
{
// Ignore blank lines
if (strLine.Length > 0)
sb.Append(strLine);
}

stream.Close();
strPage = sb.ToString();
return strPage;
}


I managed to send the page but it doesn't contain the captured values on the fields, I want to mail the page with the captured values on the fields
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,056
Latest member
GlycogenSupporthealth

Latest Threads

Top