The guts of your solution are essentially what it says to do on the Microsoft site...
But it still seems to want to pull the email message item even with the fax numbers, etc. How do I tell it to do one and then the other in a different function? I can't be the only developer to have come upon the need to do both from the same application...
Is there a setting that needs to be turned off or something somewhere? Thanks in advance for any help!
Main Topics
Browse All Topics





by: praveenpoliPosted on 2003-08-12 at 14:14:46ID: 9133705
See the following function which sends fax, here you have to notice 4th argument of SendObject (To) and you have to use the syntax '[Fax: ###-####]' for the fourth argument
("Customer s",dbOpenD ynaset)
tRTF, _
where ###-#### is your fax no to which report is to be sent, so replace this with your fax no.
Function FaxInvoices()
Dim dbsNorthwind As DATABASE
Dim rstCustomers As Recordset
Set dbsNorthwind = CurrentDb()
Set _
rstCustomers = dbsNorthwind.OpenRecordset
If MsgBox("Do you want to fax invoices" & Chr(13) & _
"to all customers using Microsoft Fax?", 4) = 6 Then
With rstCustomers
Do Until .EOF
' Create the Invoice report Filter used by the Report_Open
' event.
strInvoiceWhere = "[CustomerID] = '" & ![CustomerID] & "'"
DoCmd.SendObject acReport,"Invoice",acForma
"[fax: " & ![fax] & "]", , , , , False
.MoveNext
Loop
End With
End If
rstCustomers.Close
End Function