473,699 Members | 2,834 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Open Outlook using C#

C
Hi,

From my ASP.NET application when the user clicksa button I want to be able
to programmaticall y open Outlook, create a new mail, add attachments and set
the body text.

Is this possible?

C.

Oct 26 '06 #1
14 5184
Why would you want to open Outlook? You can do all of those things without
Outlook.

--
HTH,

Kevin Spencer
Microsoft MVP
Short Order Coder
http://unclechutney.blogspot.com

The devil is in the yada yada yada
"C" <C@discussions. microsoft.comwr ote in message
news:52******** *************** ***********@mic rosoft.com...
Hi,

From my ASP.NET application when the user clicksa button I want to be able
to programmaticall y open Outlook, create a new mail, add attachments and
set
the body text.

Is this possible?

C.

Oct 26 '06 #2
C
So my user can then just select who they want to send it to.

I will add the attachments and text from my application.

The users to receive the email may not be part of the Organisation so I
cannot provide a lookup in the application.

"Kevin Spencer" wrote:
Why would you want to open Outlook? You can do all of those things without
Outlook.

--
HTH,

Kevin Spencer
Microsoft MVP
Short Order Coder
http://unclechutney.blogspot.com

The devil is in the yada yada yada
"C" <C@discussions. microsoft.comwr ote in message
news:52******** *************** ***********@mic rosoft.com...
Hi,

From my ASP.NET application when the user clicksa button I want to be able
to programmaticall y open Outlook, create a new mail, add attachments and
set
the body text.

Is this possible?

C.


Oct 26 '06 #3
>Is this possible? <<

No.

C wrote:
Hi,

From my ASP.NET application when the user clicksa button I want to be able
to programmaticall y open Outlook, create a new mail, add attachments and set
the body text.

Is this possible?

C.
Oct 26 '06 #4
>The users to receive the email may not be part of the Organisation so I
cannot provide a lookup in the application. <<

Why can't you provide the user with a text box and have them comma
delimit the email addresses.

C wrote:
So my user can then just select who they want to send it to.

I will add the attachments and text from my application.

The users to receive the email may not be part of the Organisation so I
cannot provide a lookup in the application.

"Kevin Spencer" wrote:
Why would you want to open Outlook? You can do all of those things without
Outlook.

--
HTH,

Kevin Spencer
Microsoft MVP
Short Order Coder
http://unclechutney.blogspot.com

The devil is in the yada yada yada
"C" <C@discussions. microsoft.comwr ote in message
news:52******** *************** ***********@mic rosoft.com...
Hi,
>
From my ASP.NET application when the user clicksa button I want to be able
to programmaticall y open Outlook, create a new mail, add attachments and
set
the body text.
>
Is this possible?
>
C.
>
Oct 26 '06 #5
It is possible, but may not be necessary. If it is necessary, the newsgroup
to ask would be:

microsoft.publi c.vsnet.vstools .office

--
HTH,

Kevin Spencer
Microsoft MVP
Short Order Coder
http://unclechutney.blogspot.com

The devil is in the yada yada yada
"xAvailx" <bj******@hotma il.comwrote in message
news:11******** *************@k 70g2000cwa.goog legroups.com...
>>Is this possible? <<

No.

C wrote:
>Hi,

From my ASP.NET application when the user clicksa button I want to be
able
to programmaticall y open Outlook, create a new mail, add attachments and
set
the body text.

Is this possible?

C.

Oct 27 '06 #6
"Kevin Spencer" <sp**@uce.govwr ote in message
news:uz******** ********@TK2MSF TNGP04.phx.gbl. ..
It is possible, but may not be necessary. If it is necessary, the
newsgroup to ask would be:
As is fairly well known, Office Automation through ASP.NET is a really bad
thing to do in terms of performance.

Even Microsoft themselves strong advise against it...
http://support.microsoft.com/default...US;q257757#kb2
Oct 27 '06 #7
Oh yes, I advised against it also!

--
HTH,

Kevin Spencer
Microsoft MVP
Short Order Coder
http://unclechutney.blogspot.com

The devil is in the yada yada yada
"Mark Rae" <ma**@markNOSPA Mrae.comwrote in message
news:%2******** ************@TK 2MSFTNGP05.phx. gbl...
"Kevin Spencer" <sp**@uce.govwr ote in message
news:uz******** ********@TK2MSF TNGP04.phx.gbl. ..
>It is possible, but may not be necessary. If it is necessary, the
newsgroup to ask would be:

As is fairly well known, Office Automation through ASP.NET is a really bad
thing to do in terms of performance.

Even Microsoft themselves strong advise against it...
http://support.microsoft.com/default...US;q257757#kb2

Oct 27 '06 #8
So, you are saying that I can go to an asp.net website, and asp.net can
open outlook on my client machine and "create a new mail, add
attachments and set the body text"?

Please enlighten me! (no cockiness intended)

Thx.

Kevin Spencer wrote:
It is possible, but may not be necessary. If it is necessary, the newsgroup
to ask would be:

microsoft.publi c.vsnet.vstools .office

--
HTH,

Kevin Spencer
Microsoft MVP
Short Order Coder
http://unclechutney.blogspot.com

The devil is in the yada yada yada
"xAvailx" <bj******@hotma il.comwrote in message
news:11******** *************@k 70g2000cwa.goog legroups.com...
>Is this possible? <<
No.

C wrote:
Hi,

From my ASP.NET application when the user clicksa button I want to be
able
to programmaticall y open Outlook, create a new mail, add attachments and
set
the body text.

Is this possible?

C.
Oct 27 '06 #9
"xAvailx" <bj******@hotma il.comwrote in message
news:11******** **************@ f16g2000cwb.goo glegroups.com.. .
So, you are saying that I can go to an asp.net website, and asp.net can
open outlook on my client machine and "create a new mail, add
attachments and set the body text"?
No - what Kevin and I are saying is that there is no need whatever to open
Outlook on the client machine in order to send an email, as everything you
require (including attachments) is available through the .NET Framework,
specifically the System.Net.Mail namespace: http://www.systemnetmail.com

You must have seen webpages like this before:
http://www.markrae.com/contact/mail.aspx
Oct 27 '06 #10

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

Similar topics

2
768
by: MaxH | last post by:
I need to perform programmatically from a C# .net application the following tasks: _ open an outlook (or default e-mail client) compose message window; _ attach a document to the new message; _ set message attributes How can I do it? Thank you.
3
6571
by: Jordan | last post by:
I created and access application that sends e-mails automaticaly to our clients, over 1.500 e-mails daily. I am using the MS Outlook components to create the e-mail with HTML code. All works fine if the MS Outlook is open, but if the MS Outlook is closed, the program is unable to send more than 4 or 5 e-mails. I wish to add a initialising function which checks if the MS Outlook is open and if it isn't open it.
4
17474
by: lauren quantrell | last post by:
Is there a way to open the MS Outlook address book using VBA and then be able to do something with the return value? I want users to click an icon to open the Outlook address book then when an address is selected, populate an Access field with the address. Is this remotely possible? Thanks, lq
6
3541
by: Barkster | last post by:
I'm trying to send using outlook but I get an error on the directcast line if I don't have outlook open. Works fine if it is open. What do I need to do to be able to send without having outlook open? Thanks Dim objOutlook As New Outlook.Application Dim objMail As Outlook._MailItem = DirectCast(objOutlook.CreateItem(Outlook.OlItemType.olMailItem), Outlook._MailItem)
6
3621
by: Brad | last post by:
I have a win2003 server workstation with multiple webs, each web has it's own ip address. In VS2005, if I select to open an existing web site, select Local IIS, the dialog correctly displays a list of all of my webs, however if I attempt to open a site under and web other than localhost I receive the message: "Unable to open the Web 'http://localhost/anywebappname'. The Web 'http://localhost/anywebappname' does not exist" Obviously...
3
5808
by: bobdydd | last post by:
Hi Everybody Access 2000, Outlook 2000 Windows XP I am running the code below to open Microsoft Outlook from a Command Button. It works fine until I tried it on a machine that has Office installed on something other than the "C" drive. So can anyone advise me how to open Outlook by using a relative path rather than the code I am using here.
1
2826
by: keri | last post by:
Hi, I use the below for the user to view their outlook calendar Sub DisplayInbox() Dim myolApp As Outlook.Application Dim myNameSpace As Outlook.NameSpace Dim myFolder As Outlook.MAPIFolder Set myolApp = CreateObject("Outlook.Application") Set myNameSpace = myolApp.GetNamespace("MAPI")
2
2373
by: sreemathy2000 | last post by:
My requirement is to preload the To,cc, Subject, body ,add an attachement and automatically open the New mail screen of outlook from my web page. Send option is left to the user. I was able to find the code for this and it executed successfully in the LocalHost... I'm using Windows XP, Outlook 2003 and ASP.net 2.0 But when i deploy it in the server, it get a following error message System.Runtime.InteropServices.COMException:...
23
5961
by: andyoye | last post by:
How can I launch Outlook on users machines when they click a button on a web form (InfoPath)? Thanks
0
8685
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8612
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9171
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9032
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
7743
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5869
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4373
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
3053
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2342
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.