Wrox Programmer Forums
Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 2.0 > ASP.NET 2.0 Professional
ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old December 20th, 2007, 07:06 AM
Authorized User
Join Date: Nov 2007
Posts: 67
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to Hughesie78
Default Populate mailto address from form textbox

I have a form with a mailto in it, but I want to specify the mailto address as the value of one of my textboxes, how do I do this

   <form id="frm_Nominations" name="Survey" method=post ACTION="mailto:” ENCTYPE="text/plain">
<input name="Email" size="40" type="text" />


I want the value of the textbox “Email” to go into the mailti address, how do I do this?
Thank You
Old December 20th, 2007, 07:51 AM
Authorized User
Join Date: Nov 2007
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts

this is the code.

<%@ Page Language="VB" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<script runat="server">

    Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs)
        Response.Redirect("mailto:" & TextBox1.Text)
    End Sub

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Untitled Page</title>
    <form id="form1" runat="server">
        <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
        <asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Button" /></div>

Similar Threads
Thread Thread Starter Forum Replies Last Post
form not populating mailto in outlook 98 Hughesie78 ASP.NET 2.0 Professional 1 December 20th, 2007 10:19 AM
Mailto Form Appearance Ron Howerton HTML Code Clinic 5 September 29th, 2007 11:59 PM
Populate a Textbox in a Formview timeware ASP.NET 2.0 Basics 0 September 29th, 2006 10:08 AM
How to populate form textbox with registery key va method Pro VB 6 3 May 23rd, 2006 12:21 AM
using fields in recordset to populate textbox stoneman Access 2 October 7th, 2003 11:03 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.