Mail in Drafts

Alisha
Member Posts: 217
Hello,
I'm trying to automatically send an e-mail using the codeunit Mail and Outlook, but the message goes to Drafts. Anyone knows why?
Thanks
I'm trying to automatically send an e-mail using the codeunit Mail and Outlook, but the message goes to Drafts. Anyone knows why?
Thanks
0
Comments
-
Did you put the send option to TRUE ?
Otherwise it will just leave it in drafts.0 -
I'm using the function
MailSent := mail.NewMessage(ToName,CCName,Subject,Body,AttachFileName,OpenDialog)
where should I indicate the option SEND?
The message is sent, but it remains in Drafts.0 -
I've noticed the same behaviour. I have been using the function NewMessage in cdu 397 since version 3.60 and in version 4.0 SP2 (I haven't tested all 4.0-versions) this function behaves differently like Alisha found out: mails are not send (or at least placed in Oubox) but remain in de Draftsfolder.
I'm not sure what Mark means by putting the Send option to TRUE, because i don't think that you can do this in this function.
I have send this as a request to Microsoftsupport.
I'll let you know.
Hans0 -
Anybody have solved this?0
-
According to Microsoft:
An Outlooksetting causes this behaviour. In Outlook select Tools, Options, E-Mail Options, Advanced E-Mail Options.
You can now choose the default folder for unsent mail.
When sending mail from Navision through Cdu 397 (Mail) this setting is used.
If you have the setup so that unsent mail goes into the draft folder then irrespective of this , within 2 seconds it is passed to the Sent Items folder.
It only waits in the 'draft' folder for a short time.
Hans0 -
As I notised, mail stays in drafts folder only if you are using specific versions of Outlook.
If my thoughts are correct, you won't see this error on Office XP, Office 2003 SP2 (and maybe prior versions).
Maybe it's all because of OLHandler.dll, unfortunately can't say for sure.0 -
Does any one have any more ideas on this?
I've encoutered the same problem.
Using Outlook 2003 the email goes to Drafts for a few seconds then gets moved to Sent Items but using Outlook 2007 the email is sent but remains in the Drafts folder.
Originally the code was written in 4.01 but I've tried it using v5 with the same effect.0 -
Microsoft released a new version of the OLHandler.dll for this. According to my information this new dll should be available in 5.0, but i haven't tested it yet.
Hans0 -
I found this when doing some testing on some work I had recently completed.
On investigation i found that going into my outlook options>Mail set up>set up email accounts and directories>view or change existing account>select the account and change
There is a setting there... Use cached exchange mode.
When ticked my mails go into draft, when unticked they are sent immediately #-o
Took a bit of working out.....but I found it by comparing an email account that worked and mine.
Tim0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions