Hi everybody,
I'm kind a new at this visual basic stuff
Does anybody know why I get a compilation error when I use the following code for a button in my Form:
StuurEmail ("subject","bodytekst","email@email.com","c:\offertetemp\pdf\offerte.pdf",1,True,False)
the error states: Compilation error '=' was expected
the Subroutine is as following:
Public Sub StuurEmail(strEsubject As String, strEbody As String, strSendto As String, strAttach As String, intNoAttach As Integer, booDisplay As Boolean, booSend As Boolean)
Set email = CreateObject("Outlook.Application"
Set Item = email.createitem(0)
With Item
.Subject = esubject
.To = sendto
.Body = ebody
.Attachments.Add (strAttach)
If booDisplay = True Then .Display
If booSend = True Then .send
End With
Set email = Nothing
Set Item = Nothing
End Sub
I'm kind a new at this visual basic stuff
Does anybody know why I get a compilation error when I use the following code for a button in my Form:
StuurEmail ("subject","bodytekst","email@email.com","c:\offertetemp\pdf\offerte.pdf",1,True,False)
the error states: Compilation error '=' was expected
the Subroutine is as following:
Public Sub StuurEmail(strEsubject As String, strEbody As String, strSendto As String, strAttach As String, intNoAttach As Integer, booDisplay As Boolean, booSend As Boolean)
Set email = CreateObject("Outlook.Application"
Set Item = email.createitem(0)
With Item
.Subject = esubject
.To = sendto
.Body = ebody
.Attachments.Add (strAttach)
If booDisplay = True Then .Display
If booSend = True Then .send
End With
Set email = Nothing
Set Item = Nothing
End Sub