Computer Learning Zone CLZ Access Excel Word Windows

Extraordinary claims require extraordinary evidence.

-Carl Sagan
 
Home   Courses   TechHelp   Forums   Help   Contact   Merch   Join   Order   Logon  
 
Back to Visitor Forum    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
WhatsApp
Sarah Van Niekerk 

15 months ago
Hi Richard, I love your tech help videos and it has helped me a lot. Thank you so much.
I would like to learn how to send invoices as pdf via WhatsApp Desktop/Web.
Everyone uses WhatsApp these days and it's just easier than emailing.
Would that be at all possible.
Sami Shamma  @Reply  
             
15 months ago
Hi Sarah,

Yes, it is possible. What is your skill level?
Richard Rost  @Reply  
           
15 months ago
I don't personally use WhatsApp much myself. I haven't installed it on my phone. I did notice when I was traveling over in Europe over the summer that everyone over there uses it. Anyhow I asked GPT what's possible and here's what it told me:

As for sending invoices as PDFs via WhatsApp Desktop/Web, it's definitely possible, but there's no direct integration in Microsoft Access to send files via WhatsApp. However, here's a simple workaround:

1. Export your invoice as a PDF from Access using the DoCmd.OutputTo method.
2. Save the PDF to your local drive.
3. Open WhatsApp Desktop/Web, find the contact or group, and use the paperclip icon to upload and send the PDF.

WhatsApp does not have an official public API for personal use that supports sending messages with attachments (like PDFs) automatically. The WhatsApp Business API is available, but it's aimed at medium and large businesses, and it comes with limitations and setup requirements.

For personal use, there are a couple of workarounds:

1. Using `Shell` to open WhatsApp Web and simulate the attachment process:  
   This involves VBA automating the browser to navigate to WhatsApp Web and attach a file. However, this is fragile and prone to breaking if WhatsApp changes its UI.

2. Third-party tools and libraries:  
   Some unofficial solutions exist (like Python's `pywhatkit` library), but they violate WhatsApp's terms of service and could result in account suspension.

3. Manual process with automation assistance:  
   You can automate the PDF generation and saving in a specific folder with a VBA script and then give users a message box prompt with the link to the file, making it easier to upload it to WhatsApp manually.

Here's an example of how you can automate generating a PDF and opening WhatsApp Web in a browser to help the user send the file manually:

CodeSub SendInvoiceViaWhatsApp()
    Dim strFilePath As String
    Dim strContact As String
    Dim strMessage As String
    Dim strURL As String

    ' Export the invoice as a PDF
    strFilePath = "C:\Invoices\Invoice123.pdf" ' Replace with your actual path
    DoCmd.OutputTo acOutputReport, "rptInvoice", acFormatPDF, strFilePath, False

    ' Set the contact's WhatsApp number (include country code, no spaces or special characters)
    strContact = "1234567890" ' Replace with the recipient's WhatsApp number
    
    ' Set a default message (URL encoding for spaces and special characters)
    strMessage = "Hello, here is your invoice."

    ' Construct the WhatsApp URL
    strURL = "https://wa.me/" & strContact & "?text=" & Replace(strMessage, " ", "%20")

    ' Open WhatsApp Web with the message
    Application.FollowHyperlink strURL
    
    MsgBox "PDF generated and ready to send via WhatsApp. Please attach " & strFilePath, vbInformation
End Sub


How this works:
1. The `DoCmd.OutputTo` command exports the invoice as a PDF.
2. It constructs a WhatsApp Web URL with a pre-filled message.
3. `Application.FollowHyperlink` opens WhatsApp Web with the recipient's number and message.
4. The user is prompted to attach the generated PDF manually.

Note:
- Automating the file upload is not possible directly due to WhatsApp's limitations.
- This approach is semi-automated. The user still needs to attach the file manually.
- Make sure to enable trusted VBA code execution in Access for this to run without warnings.


This thread is now CLOSED. If you wish to comment, start a NEW discussion in Visitor Forum.
 

Next Unseen

 
New Feature: Comment Live View
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2026 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 5/8/2026 5:06:34 PM. PLT: 0s