Welcome Guest. Please Login or Register. Apr 5th, 2018, 11:03pm
ATTENTION MEMBERS: Conforums will be closing it doors and discontinuing its service on April 15, 2018. Ad-Free has been deactivated. Outstanding Ad-Free credits will be reimbursed to respective payment methods.
If you require a dump of the post on your message board, please come to the support board and request it.
Re: Sending automated mail
« Reply #5 on: May 8th, 2010, 12:07pm »
I totally agree with your remarks, the thought that microsoft rules all by excluding others is not pleasant. But as the mailserver in question only works with outlook, I have no choice. The only thing to try is fooling the server into believing the mail came from a outlook client, but this task lies outside my capabilities. The only drawback in using the ShellExecute method is that the email client application opens up for a brief moment, and this is far from elegant, but I can live with it.
The only drawback in using the ShellExecute method is that the email client application opens up for a brief moment, and this is far from elegant, but I can live with it.
You could try opening it with the window minimized (set the nShowCmd parameter of ShellExecute to SW_SHOWMINIMIZED) or even hidden (SW_HIDE). Since it won't then have input focus you will need to replace your 'faked' keyboard input with proper Windows command messages, but that is safer and more elegant anyway. You'll need Outlook's window handle for that, which you can probably get using FindWindow, and some detective work to find the right menu IDs!