2
For each Execution of the Deletesel function, a "WINWORD" is open in memory, even with the Close and/or Quit command it does not close.
Sub DeleteSel(msg As Outlook.MailItem)
Dim objDoc As Object
Dim objBkm As Object
Set objDoc = CreateObject("Word.Application")
objDoc.Visible = True
objDoc.Activate
On Error Resume Next
Set objDoc = msg.GetInspector.WordEditor
Set objBkm = objDoc.Bookmarks("_MailAutoSig")
If Not objBkm Is Nothing Then
objBkm.Select
objDoc.Windows(1).Selection.Delete
End If
objDoc.Close
objBkm.Close
Set objBkm = Nothing
Set objDoc = Nothing
End Sub
Would anyone have any tips ?
Even if QUIT works, I could not use this feature, because if the user really is with Word Open, would close the user’s job.
– Roberto Valentim
Cool this option @danieltakeshi, thanks!!
– Evert