|
-
Jan 15th, 2007, 07:25 AM
#1
Thread Starter
Hyperactive Member
How to send Mail Item manually
Hi, All
I m creating an Addin to check whether user has not filled any recipient of the Mail. In this case (if user has left all of its recipients blank), I want to send my mails to a specefied email address.
I have written the code for it in myOLApp_ItemSend but problem is that
when I leave blank all its recipient then a message comes .
"There must be at least one name or distribution list in the TO,cc,bcc Box" .
My code executes after this message.
I don't want this message and want to execute my code written in
myOLApp_ItemSend Procedure.
Any help is appriciated
Thanks
Using .NET 3.5 (VS 2008) And XP SP2

-
Jan 15th, 2007, 05:52 PM
#2
Re: How to send Mail Item manually
If they leave the To blank and you have a CC or BCC I would suggest that when its blank you substitute your email address in the to and be done with it.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Jan 16th, 2007, 12:21 AM
#3
Thread Starter
Hyperactive Member
Re: How to send Mail Item manually
I want to check when user leave blank To,CC,BCC then this mail should go to a particular email Address, without giving any message.
Currently my problem is that whenever user leave blank To,CC,BCC then that message appears.
Using .NET 3.5 (VS 2008) And XP SP2

-
Jan 16th, 2007, 01:12 AM
#4
Re: How to send Mail Item manually
Hmm, havent tested it but does the ItemSend event still fire before the error msg comes up?
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Jan 16th, 2007, 02:12 AM
#5
Thread Starter
Hyperactive Member
Re: How to send Mail Item manually
No sir,
Actually when I want to send a mail leaving to,cc,bcc fields blank, then that message appears(after clicking the SEND button) and after that my code executes that is written in myOlApp_ItemSend Procedure.
My requirements is that I want to leave blank to,cc,bcc and want to send mail to a default recipient that is given in my code.
but when I leave blank to,cc,bcc that message appears and I have to enter something in anyone field, otherwise this message appears again and again, that I don't want.
I don't know how to stop it.
Please reply me soon
Using .NET 3.5 (VS 2008) And XP SP2

-
Jan 16th, 2007, 03:09 AM
#6
Re: How to send Mail Item manually
If the msg is popping up first before the code execute s the item send event then you cant do it from managed/automation code. You will need to modify the Outlook Form and add VB Script code to the event and see if it fires before the error msg. I doubt that it will but could be worth a try.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Jan 16th, 2007, 10:42 AM
#7
Thread Starter
Hyperactive Member
Re: How to send Mail Item manually
Thanks RobDog
could you explain the managed/automation code. or
any sample or helping hints.
Thanks again
Using .NET 3.5 (VS 2008) And XP SP2

-
Jan 16th, 2007, 11:19 AM
#8
Re: How to send Mail Item manually
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Jan 17th, 2007, 02:21 AM
#9
Thread Starter
Hyperactive Member
Re: How to send Mail Item manually
Thanks a lot for reply RobDog But As I know Outlopk's Message form cannot be customized.
AM I right.
anyways what is the event that cause that popup to appear. If this can be catch ,
then rest of thing is ok.
Any Idea??
Using .NET 3.5 (VS 2008) And XP SP2

-
Jan 17th, 2007, 03:47 AM
#10
Re: How to send Mail Item manually
So you didnt see my FAQ link I posted in the post above?
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|