Memuat
Memuat
Automatic Email Sending for laundry
0 views
The macro builds an Outlook email with a totals summary and attaches the file. Recipient and subject are read from Dashboard cells.

Periodic reports go out without writing emails by hand.
The real project file is available. It is not just the picture above: you get the working file with every formula in place. It can be downloaded after payment, and we send the download link by WhatsApp or email.
ZIP: .xlsx workbook + VBA macro module (.zip)
| Cell | Formula | What it does |
|---|---|---|
| J2 | ="Ringkasan "&TEXT(TODAY(),"dd mmmm yyyy") | Auto-generated email subject. |
| J3 | =SUM(Data!G:G) | Total quoted in the email body. |
| J4 | =COUNTIFS(Data!F:F,Rekap!B2) | Number of transactions with the first status. |
The macro module is delivered as a separate Modul_Makro.bas file inside the ZIP. Import it through Alt+F11. A short excerpt:
Sub KirimEmail()
Dim ol As Object, mi As Object, ws As Worksheet, tmp As String
Set ws = ThisWorkbook.Sheets("Dashboard")
If ws.Range("J5").Value = "" Then MsgBox "Isi alamat email di J5.": Exit Sub
tmp = ThisWorkbook.Path & "\Kirim_" & Format(Date, "yyyymmdd") & ".xlsx"
ThisWorkbook.SaveCopyAs tmp
On Error GoTo gagal
Set ol = CreateObject("Outlook.Application")
Set mi = ol.CreateItem(0)
With mi
.To = ws.Range("J5").Value
.Subject = ws.Range("J2").Value
.Body = "Halo," & vbCrLf & "Total transaksi: " & Format(ws.Range("J3").Value, "#,##0") & vbCrLf & "Terlampir berkas lengkap."
.Attachments.Add tmp
.Display
End With
Exit Sub
gagal:
MsgBox "Outlook tidak tersedia: " & Err.Description, vbCritical
End SubColumns of the Data sheet:
| Laundry Service | Price |
|---|---|
| Wash and Iron per Kg | 7,000 |
| Wash and Fold per Kg | 5,000 |
| Iron Only per Kg | 4,000 |
| Express 6 Hour Wash per Kg | 12,000 |
| Blanket per Piece | 25,000 |
| Bed Sheet Set | 20,000 |
| Suit or Blazer | 30,000 |
| Sneakers Cleaning | 35,000 |
| Large Stuffed Toy | 25,000 |
| Pickup and Delivery | 10,000 |
The sample data is synthetic.
Yes. The picture above is only a preview. After payment we send the download link of the real project file (a ZIP containing the .xlsx workbook and the macro module) by WhatsApp or email.
No. The sample data is synthetic and only shows how the formulas behave. Replace it with your own data and the formulas keep working.
Yes, as a separate order. Message us on WhatsApp with a short description of your columns and what you want to see.
Sample data is synthetic. Excel is a trademark of Microsoft Corporation.
Back to Excel portfolio