On Wed, Aug 21, 2019 at 12:22 AM MB Software Solutions, LLC <
[email protected]> wrote:

> VFP9SP2 app
>
> Customer uses Outlook and wants the app to generate an email to a given
> email address from the app AND attach certain documents to it.  Customer
> will preview it and then manually hit "Send" on their own.
>

Despite its advanced age (16!) this paper still has a few good pointers in
it:

https://www.tedroche.com/Present/2003/OutlookAutomation.html

"However, just because you can do something doesn't mean that you should. "
made me laugh.

The canonical reference is Office Automation with Visual FoxPro by Tamar E.
Granor and Della Martin, edited by yours truly, and more info can be found
at:

http://hentzenwerke.com/catalog/autofox.htm

Note that there are sample chapters and downloads available. The site says
"Out of Print" but I think the ebook may still be order-able.

Bear in mind that MSFT regularly changes and breaks their APIs, or the
mechanism to access the APIs, since skript kiddies regularly take over
Outlook and use it to send spam and perpetrate identity theft. Just in the
last month's patches, they broke portions of VB6, VBA and VBScript. I
shipped a number of apps with Office Automation back in the day, and
between Office object model changes and security enhancements required some
major rewriting, sometimes sprung on us by surprise. It was a learning
experience in how Microsoft supports developers of their products.

Rather than tightly coupling your VFP app with this week's version of
Outlook, you might consider how an arm's length relationship could work out
better for all involved. You could use WestWind Client Tools, BLAT, or
command-line mail tools [1] to draft the message and send it to the
customer, who could review it and forward it to the client, with the
downside they would need to specify the forwarding address, or you could
write a .NET app integrated into Outlook that could read a queue written
into a database table by FoxPro and do the automation and processing in
.NET.

And remember, kids, MAPI Bad! SMTP Good. Just Say No. We Can Eliminate It
In Our Lifetimes.

Good luck!

[1] I also wrote a white paper "Email Without Outlook" for this very
reason: https://www.tedroche.com/Present/2002/emailwooutlook.html

-- 
Ted Roche
Ted Roche & Associates, LLC
http://www.tedroche.com


--- StripMime Report -- processed MIME parts ---
multipart/alternative
  text/plain (text body -- kept)
  text/html
---

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox
OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech
Searchable Archive: https://leafe.com/archives
This message: 
https://leafe.com/archives/byMID/CACW6n4vnOj5KqWdiha55mAt=Fv+w9HibSCLznMw=vtay2-q...@mail.gmail.com
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to