473,382 Members | 1,447 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,382 software developers and data experts.

Emulate HREF Mailto: in a form

I'm have a form with a datagrid showing a checkbox for each row. I want the
user to be able to click a checkbox and then click a button that sends an
email similar to how the HREF MailTo: works. I can't embed the MailTo: in
the webpage b/c the button has to determine which row has a checkbox, pull
data from SQL and then build the email content. I originally wrote the code
using System.Web.Mail classes but the client doesn't like it b/c they want
each user's own email app to open so they can modify the email and
add/remove recipients. One option is to have an Href link on each row of the
table that they can click on, but this results in lots of data manipulation
as well as tons of excess HTML on the page.

Does anyone know how to emulate the HREF MailTo: functionality in an ASP.NET
page so I can create the link dynamically and let the browser control
opening the user's default email program with the data filled in already
from this dynamic HREF link?

Thanks,

Brian
Nov 19 '05 #1
3 2186
you'll have to pass it to the client

--
Curt Christianson
Site & Scripts: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com
"Brian Bischof" <Br***@NoSpamBischofSystems.com> wrote in message
news:OV****************@TK2MSFTNGP11.phx.gbl...
I'm have a form with a datagrid showing a checkbox for each row. I want
the
user to be able to click a checkbox and then click a button that sends an
email similar to how the HREF MailTo: works. I can't embed the MailTo: in
the webpage b/c the button has to determine which row has a checkbox, pull
data from SQL and then build the email content. I originally wrote the
code
using System.Web.Mail classes but the client doesn't like it b/c they want
each user's own email app to open so they can modify the email and
add/remove recipients. One option is to have an Href link on each row of
the
table that they can click on, but this results in lots of data
manipulation
as well as tons of excess HTML on the page.

Does anyone know how to emulate the HREF MailTo: functionality in an
ASP.NET
page so I can create the link dynamically and let the browser control
opening the user's default email program with the data filled in already
from this dynamic HREF link?

Thanks,

Brian

Nov 19 '05 #2
Can you give me a little more info? Pass it to the client using JavaScript?
"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:O5***************@TK2MSFTNGP09.phx.gbl...
you'll have to pass it to the client

--
Curt Christianson
Site & Scripts: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com
"Brian Bischof" <Br***@NoSpamBischofSystems.com> wrote in message
news:OV****************@TK2MSFTNGP11.phx.gbl...
I'm have a form with a datagrid showing a checkbox for each row. I want
the
user to be able to click a checkbox and then click a button that sends an email similar to how the HREF MailTo: works. I can't embed the MailTo: in the webpage b/c the button has to determine which row has a checkbox, pull data from SQL and then build the email content. I originally wrote the
code
using System.Web.Mail classes but the client doesn't like it b/c they want each user's own email app to open so they can modify the email and
add/remove recipients. One option is to have an Href link on each row of
the
table that they can click on, but this results in lots of data
manipulation
as well as tons of excess HTML on the page.

Does anyone know how to emulate the HREF MailTo: functionality in an
ASP.NET
page so I can create the link dynamically and let the browser control
opening the user's default email program with the data filled in already
from this dynamic HREF link?

Thanks,

Brian


Nov 19 '05 #3
Here is what I've done so far. It's a hack, but I'm hoping they will accept
it unless someone here posts something better.

I have the button pass the email info to another page which simply displays
the Subject and Body info on the screen. I say something like, "Click on the
link below to send the following email" and I also hardcode the link to be
the Href:EmailTo info that was passed from the previous page. This lets me
build a single href link in code prior to displaying the page so the user so
they can click on it like a regular link.

HTH,

Brian

"Brian Bischof" <Br***@NoSpamBischofSystems.com> wrote in message
news:u4****************@TK2MSFTNGP09.phx.gbl...
Can you give me a little more info? Pass it to the client using JavaScript?

"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:O5***************@TK2MSFTNGP09.phx.gbl...
you'll have to pass it to the client

--
Curt Christianson
Site & Scripts: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com
"Brian Bischof" <Br***@NoSpamBischofSystems.com> wrote in message
news:OV****************@TK2MSFTNGP11.phx.gbl...
I'm have a form with a datagrid showing a checkbox for each row. I want the
user to be able to click a checkbox and then click a button that sends an email similar to how the HREF MailTo: works. I can't embed the MailTo: in the webpage b/c the button has to determine which row has a checkbox, pull data from SQL and then build the email content. I originally wrote the
code
using System.Web.Mail classes but the client doesn't like it b/c they want each user's own email app to open so they can modify the email and
add/remove recipients. One option is to have an Href link on each row of the
table that they can click on, but this results in lots of data
manipulation
as well as tons of excess HTML on the page.

Does anyone know how to emulate the HREF MailTo: functionality in an
ASP.NET
page so I can create the link dynamically and let the browser control
opening the user's default email program with the data filled in already from this dynamic HREF link?

Thanks,

Brian



Nov 19 '05 #4

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

Similar topics

2
by: Bill Petrol | last post by:
I'm trying to send a link with a querystring as the body of an email message. My HTML syntax looks something like this: <a href="mailto:xxx@yyy.com?Subject=<? print $subject ?>&Body=<? print...
1
by: Jack | last post by:
Hi, I have the following code which displays email address from a database However, I need to have the email address highlighted so that on clicking the email box would open up with the email name...
1
by: Jim Mitchell | last post by:
I like the abilith to use href=mailto:xxx@xxx.com?body=This is in the body The problem is that I can not get the default e-mail tool (Outlook) to open up in html format. It seems to only support...
4
by: Jamie Jackson | last post by:
I know that it's possible to return false in an onClick to disable a link. Is there a way to do this within the HREF attribute? Something like: <a href="javascript: return false;"> ? Thanks,...
2
by: Brvsra | last post by:
Javascript Experts, I know very little about javascript and could use someone's help. I have created a function to send an email, listed below is the function. The function works fine, with...
61
by: /* frank */ | last post by:
I have to do a homework: make a CPU simulator using C language. I have a set of asm instructions so I have to write a program that should: - load .asm file - view .asm file - do a step by step...
7
by: C a r l o s A n t o n i o | last post by:
Hello, I have to submit a file via HyperTerminal using my PC's internal modem on a daily basis. Does anybodoy know how to accomplish this in VS2005? Any language is good, VB preferred. ...
5
by: annaGold | last post by:
Hello, I wrote this simple javascript to demonstrate my problem with IE6 & 7. The code works find in Mozilla, but in IE my email link on the page is changed to the new href. Only href should change,...
14
by: Eugeny Myunster | last post by:
Hello all, How can i emulate sizeof() only for integers?
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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...

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.