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

Construct MSG file at runtime from details

Hi

i maintain the message body and some headers like fromid,
receiveddate,etc in access database.

I am able to create a .MSG file and to post it back to inbox. But
creating and maintaining .MSG files for all the mails will be a
head-ache.

What i wanted to do is maintain all the details in database and need
to create .msg files as and when i need. My queries are

1)Is it possible to create a new message file from the details i have
in database??

2)What is the component used in outlook while we save the message as
..msg file. Is it possible to use that component?

Thanks
Anushya
Nov 15 '05 #1
4 7815
1. If you want to create an MSG file first, populate it with the properties
and then import it back into Outlook, why do you need an MSG file? Wouldn't
it be easier to create a message directly in Outlook and populate it with
properties from your DB?
2. Outlook uses Extended MAPI to create/access MSG files. You can do the
same if you were using Extended MAPI from C++/Delphi.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"Anushya" <v_*******@hotmail.com> wrote in message
news:80*************************@posting.google.co m...
Hi

i maintain the message body and some headers like fromid,
receiveddate,etc in access database.

I am able to create a .MSG file and to post it back to inbox. But
creating and maintaining .MSG files for all the mails will be a
head-ache.

What i wanted to do is maintain all the details in database and need
to create .msg files as and when i need. My queries are

1)Is it possible to create a new message file from the details i have
in database??

2)What is the component used in outlook while we save the message as
.msg file. Is it possible to use that component?

Thanks
Anushya

Nov 15 '05 #2
1. If you want to create an MSG file first, populate it with the properties
and then import it back into Outlook, why do you need an MSG file? Wouldn't
it be easier to create a message directly in Outlook and populate it with
properties from your DB?
2. Outlook uses Extended MAPI to create/access MSG files. You can do the
same if you were using Extended MAPI from C++/Delphi.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"Anushya" <v_*******@hotmail.com> wrote in message
news:80*************************@posting.google.co m...
Hi

i maintain the message body and some headers like fromid,
receiveddate,etc in access database.

I am able to create a .MSG file and to post it back to inbox. But
creating and maintaining .MSG files for all the mails will be a
head-ache.

What i wanted to do is maintain all the details in database and need
to create .msg files as and when i need. My queries are

1)Is it possible to create a new message file from the details i have
in database??

2)What is the component used in outlook while we save the message as
.msg file. Is it possible to use that component?

Thanks
Anushya

Nov 15 '05 #3
Hi
Thanks for your reply

1) How do you set properties and import a mail item back to inbox? Again i
need to set read-only properties like senderName, received date?

2) How to create MSG file from Extended MAPI?

Anushya

"Dmitry Streblechenko \(MVP\)" <dm****@dimastr.com> wrote in message news:<eL**************@tk2msftngp13.phx.gbl>...
1. If you want to create an MSG file first, populate it with the properties
and then import it back into Outlook, why do you need an MSG file? Wouldn't
it be easier to create a message directly in Outlook and populate it with
properties from your DB?
2. Outlook uses Extended MAPI to create/access MSG files. You can do the
same if you were using Extended MAPI from C++/Delphi.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"Anushya" <v_*******@hotmail.com> wrote in message
news:80*************************@posting.google.co m...
Hi

i maintain the message body and some headers like fromid,
receiveddate,etc in access database.

I am able to create a .MSG file and to post it back to inbox. But
creating and maintaining .MSG files for all the mails will be a
head-ache.

What i wanted to do is maintain all the details in database and need
to create .msg files as and when i need. My queries are

1)Is it possible to create a new message file from the details i have
in database??

2)What is the component used in outlook while we save the message as
.msg file. Is it possible to use that component?

Thanks
Anushya

Nov 15 '05 #4
1. You can't do that in OOM, only in Extended MAPI, CDO 1.21 or Redemption.
Namespace.CreateItemFromTemplate() is the closest thing to an import in
Outlook Object Model, but it does not work reliably.
2. In Outlook Object Model call MailItem.SaveAs(path, olMsg). In Extended
MAPI, see Q171907 on MSDN.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"Anushya" <v_*******@hotmail.com> wrote in message
news:80**************************@posting.google.c om...
Hi
Thanks for your reply

1) How do you set properties and import a mail item back to inbox? Again i
need to set read-only properties like senderName, received date?

2) How to create MSG file from Extended MAPI?

Anushya

"Dmitry Streblechenko \(MVP\)" <dm****@dimastr.com> wrote in message

news:<eL**************@tk2msftngp13.phx.gbl>...
1. If you want to create an MSG file first, populate it with the properties and then import it back into Outlook, why do you need an MSG file? Wouldn't it be easier to create a message directly in Outlook and populate it with properties from your DB?
2. Outlook uses Extended MAPI to create/access MSG files. You can do the
same if you were using Extended MAPI from C++/Delphi.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"Anushya" <v_*******@hotmail.com> wrote in message
news:80*************************@posting.google.co m...
Hi

i maintain the message body and some headers like fromid,
receiveddate,etc in access database.

I am able to create a .MSG file and to post it back to inbox. But
creating and maintaining .MSG files for all the mails will be a
head-ache.

What i wanted to do is maintain all the details in database and need
to create .msg files as and when i need. My queries are

1)Is it possible to create a new message file from the details i have
in database??

2)What is the component used in outlook while we save the message as
.msg file. Is it possible to use that component?

Thanks
Anushya

Nov 15 '05 #5

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

Similar topics

3
by: Peter Blum | last post by:
I have built an assembly (dll) from which I expect third parties to subclass. As a result, when my assembly has a version change, it will cause any third party assembly based on it to break unless...
1
by: Chris | last post by:
I have seen the posts on various places on the internet about .NET framework mismatch issues and I don't think that is my problem. ; ) When I execute the following C++.NET code: String...
1
by: Murat Dikici | last post by:
Hello, The file structure on the server is: /FileUpload - Web.config - upload.aspx I try to run the upload.aspx but it gives me a runtime error message like this: ----------------
8
by: Subra Mallampalli | last post by:
Hi, I am trying to use <runtime> section within the web.config file. However, the contents of the <runtime> section seem to be ignored. What am i missing here? Is <runtime> section not used by...
2
by: js | last post by:
I got this error when I moved my application to a new Windows 2003 server. I installed and recompiled the 'Microsoft.Practices.EnterpriseLibrary - June 2005" then added these assemblies to the...
3
by: John K | last post by:
I am trying to eliminate the capability of displaying the details of a web service by disabling WSDL generation in the web.config file. I have made the following changes to the web.config: ...
1
by: moondaddy | last post by:
running vs2005 I have a small test website called TestPublish which has default.aspx, ErrorPage.aspx and testpage.htm. The default page just says hello world and no other code and the errorpage...
2
by: Bhavesh | last post by:
Hi everybody, I have problem in copying file from DatabaseServer to WebServer.Both machines are on LAN. Let me explain in details what i am doing & wht i want to achieve... I am using...
3
by: vainstah | last post by:
Hello Guys and Galls, To start off, I have reached the solution I was looking for, but I would like comments and feedback on the solution I have reached and tips/tricks on making it more elegant....
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
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...
0
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...

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.