Click here to Skip to main content
15,884,537 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I would like to open OUT LOOK mail client for sending mail with CC, BCC, subjects- I made the following javascript function to open out look on clicking a link button--
Link button event has been given below.

JavaScript
function hello(sub, cc, bcc) {


var myWindow = window.open("mailto:?subject=" + sub + "&cc= " + cc, '', '', 'titlebar=no,menubar=no,width=1,height=1,visible=none', '_top');
myWindow.close();
}

****************************aspx.cs file
C#
protected void LinkButton1_Click(object sender, EventArgs e)
{
..............................................
/**bccId and CCI are being fetched from table through query**/

Page.RegisterStartupScript("key1", "<script = language='javascript'>hello('" + bccId + "','" + ccId + "');</script>");
}

*******aspx page fro link button...

..................
C#
<asp:LinkButton ID="LinkButton1" runat="server" Height="22px" Width="140px"
onclick="LinkButton1_Click" >E-mail IN

............

Now the problems is when this code is run in Windows server 2008, then the outlook is being opened with another unnecessary pop up in IE9 but in Mozilla it is not coming, only Outlook is being opened..

In IE 9 I only need to open the outlook express...but it not happening...

Need a prompt solution...ion...
Posted
Updated 21-May-12 20:46pm
v3

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900