Hello
Quick question like to know if if this possible
I put together this little bit of code. This count all the filed in folder then sent a email,
Would like to know if there a way to sent out a different message depend on if the is any file.
Private Sub Command0_Click()
Dim file1 As Object
Dim filecount1 As Long
With CreateObject("Scripting.FileSystemObject").GetFolder("P:\")
For Each file In .Files
If file.Name Like "*" Then
filecount1 = filecount + 1
End If
Next file
End With
<?xml:namespace prefix = o ns = "urn:schemas-microsoft-comfficeffice" /><o></o>
Strbodytext1 = "Option 1" if equal or more
Strbodytext2 = "Option 2" no files in folder
DoCmd.SendObject , "", "", "", "", "Jonathan Pernice", "Test", Strbodytext1, False, ""
End Sub
Thanks
Jonathan
Quick question like to know if if this possible
I put together this little bit of code. This count all the filed in folder then sent a email,
Would like to know if there a way to sent out a different message depend on if the is any file.
Private Sub Command0_Click()
Dim file1 As Object
Dim filecount1 As Long
With CreateObject("Scripting.FileSystemObject").GetFolder("P:\")
For Each file In .Files
If file.Name Like "*" Then
filecount1 = filecount + 1
End If
Next file
End With
<?xml:namespace prefix = o ns = "urn:schemas-microsoft-comfficeffice" /><o></o>
Strbodytext1 = "Option 1" if equal or more
Strbodytext2 = "Option 2" no files in folder
DoCmd.SendObject , "", "", "", "", "Jonathan Pernice", "Test", Strbodytext1, False, ""
End Sub
Thanks
Jonathan