title: Why is the Send method not working on VBA project?
body: <p>I'm trying to send mails using VBA code. We deleted the display method but it is still not working.</p>
  <p>It displays the email with every property of the object <strong>Correo</strong>, but it's not sending.</p>
  <p>It raises error 438.</p>
  <pre class="lang-vb prettyprint-override"><code>Sub sendmail(propietario As String, activo As String, departamento As String)
  
      Dim OutApp As Object
      Dim Correo As Object
  
      With Application
          .EnableEvents = False
          .ScreenUpdating = False
      End With
  
      On Error Resume Next
      Set OutApp = GetObject(&quot;&quot;, &quot;Outlook.Application&quot;)
      Err.Clear
      If OutApp Is Nothing Then Set OutApp = CreateObject(&quot;Outlook.Application&quot;)
      OutApp.Visible = True
      Set Correo = OutApp.CreateItemFromTemplate(&quot;C:\Users\plantilla.oft&quot;)
  
      With Correo
          .To = propietario
          .CC = &quot;mail@gmail.com&quot;
          .Subject = &quot;[Recertificación de Usuarios] &quot; &amp; activo &amp; &quot; - &quot; &amp; departamento
          .Attachments.Add &quot;C:\Users\hello.xlsx&quot;
          Set .SendUsingAccount = OutApp.Session.Accounts.Item(1)
          .Display
          .Send
      End With
  
      With Application
          .EnableEvents = True
          .ScreenUpdating = True
      End With
  
      Set Correo = Nothing
      Set OutApp = Nothing
  
  End Sub
  </code></pre>