open new Outlook from website, too long mailTo Link, *.eml file bcc field not loaded

前端 未结 3 1383
长发绾君心
长发绾君心 2021-01-18 05:44

I\'m trying to open a *.eml file with Microsoft Outlook 2010 and got problems with the bcc field.

Here is my eml file:

3条回答
  •  说谎
    说谎 (楼主)
    2021-01-18 06:21

    I found a solution for my given problem.

    MailTo links are still too long and *.eml files won't work. But it's possible to generate a *.vbs file (Visual Basic Script) which will open up a new Outlook E-Mail send form with all the fields I need and a very long Body (tested with over 50000 characters). Here is a sample code for such an *.vbs file:

    'Create an Outlook application object 
    Set objoutlookApp = CreateObject("Outlook.Application") 
    
    'Create Message 
    Set objmessage = objoutlookApp.CreateItem(olMailItem) 
    objmessage.TO = "mail1@domain.com;mail2@example.de"
    objmessage.CC = "cc1@x.com;cc2@y.de"
    objmessage.BCC = "bcc@domain.com"
    objmessage.Subject = "E-Mail Subject"
    objmessage.Body = "Here comes some text, followed by a newLine" & vbNewLine _
    & "and here is a second Line with some special characters like the paragraph: " & chr(167) & ", a german umlaut: " & chr(228) & " or some quotes: "". Hope this will help!"
    objmessage.display
    
    set objmessage = Nothing
    set objoutlookApp = Nothing
    
    wscript.quit
    

提交回复
热议问题