Bonjour,
En mettant
   .Attachement =array(annexes(0))
cela fonctionne chez moi sur Windows et libreoffice 6.1.0.3
Claude
Le 27/09/2018 à 13:13, Algol Formation a écrit :
Bonjour à tous,
Gros souci avec la commande sendSimpleMailMessage qui provoque dans le 
code suivant l'erreur :
"Invalid Attachement file URL"
Sub EnvoiCourriel
Dim Messagerie As Object, Client As Object, Courrier As Object, 
annexes(1) As String
   Messagerie = CreateUnoService("com.sun.star.system.SimpleSystemMail")
   Client = Messagerie.querySimpleMailClient()
   Courrier = Client.createSimpleMailMessage()
   With Courrier
      .Subject = "Test envoi courriel"
      .Recipient = "algol.formations@inforbur.com"
      annexes(0) = convertToURL("D:\Libre 
Office\LOCalc\Calc_avec_codes\adresses.txt")
      .Attachement = annexes(0)
      .body = "ceci est un test"
/*Client.sendSimpleMailMessage(Courrier,0) :-\*/
   End With
End Sub
Merci de votre aide.
Cordialement
Michel Blanchard
---
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast.
https://www.avast.com/antivirus
--
Envoyez un mail à users+unsubscribe@fr.libreoffice.org pour vous désinscrire
Les archives de la liste sont disponibles à https://listarchives.libreoffice.org/fr/users/
Privacy Policy: https://www.documentfoundation.org/privacy
Context
   
 
  Privacy Policy |
  
Impressum (Legal Info) |
  
Copyright information: Unless otherwise specified, all text and images
  on this website are licensed under the
  
Creative Commons Attribution-Share Alike 3.0 License.
  This does not include the source code of LibreOffice, which is
  licensed under the Mozilla Public License (
MPLv2).
  "LibreOffice" and "The Document Foundation" are
  registered trademarks of their corresponding registered owners or are
  in actual use as trademarks in one or more countries. Their respective
  logos and icons are also subject to international copyright laws. Use
  thereof is explained in our 
trademark policy.