Solved

Asp.net mvc4

Posted on 2014-11-17
3
407 Views
Last Modified: 2015-03-27
Hi guys ,

I have some report button in my application "asp.net mvc4" and I would like to open outlook send message when users click on the button. is it possible to do so?  or there is other way to do it.

Please , advice.



Thansk ,
0
Comment
Question by:Moti Mashiah
  • 2
3 Comments
 
LVL 18

Accepted Solution

by:
Richard Lee earned 500 total points
ID: 40449424
To open outlook from  web application it would have to be set at the user's default email application and a link such as the following would have to be in your application.

<a href="mailto:abc@abc.com?Subject=ABC&Body=Body" title="title" >Email</a>

Open in new window


Since I don't believe that is what you are asking for, but more of an automated approach I would suggest that it would be better to send the email from the web application. Provide the fields for the user to enter the message and subject and when the Send button is clicked then send the email using some SMTP service from your application.

I wrote a component Fluent.NET Mail that allows the easy sending of email and constructs personalised emails.

new Mail()
    .Html(new MessageTemplate()
        .FromText("This is my email with {content} text")
        .DataFrom(new { content = "html" })
        .BetweenBraces())
    .To(new MailBox(emailAddress))
    .From(new MailBox(emailAddress))
    .Subject("Fluent API .NET 2")
    .Timeout(5000)
    .SmtpServer("[your smtp server]")
    .Send();

Open in new window


http://www.avantprime.com/products/docs/fluent-net-mail/

I hope this helps.
0
 
LVL 1

Author Comment

by:Moti Mashiah
ID: 40450168
Thank you for your answer.

please , would you be able to send me some instruction how to implement the HTML page mvc for that and the controller side what you did already.

I'm really new to this and i need some step by step instruction.

please see attachment of my application to get any idea;

when you click on report button it should popup window (i assume with jquery ) and this window should give you the page email view to send email.

thanks email.JPG
0
 
LVL 1

Author Closing Comment

by:Moti Mashiah
ID: 40692056
solved
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today is the age of broadband.  More and more people are going this route determined to experience the web and it’s multitude of services as quickly and painlessly as possible. Coupled with the move to broadband, people are experiencing the web via …
This article is for Object-Oriented Programming (OOP) beginners. An Interface contains declarations of events, indexers, methods and/or properties. Any class which implements the Interface should provide the concrete implementation for each Inter…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question