how to add multiple envelopes to word doc


  • Hi all,
     i am not able to  add multiple envelopes in word doc

    using below code i can add only one envelope  to word doc

    Dim Act As Microsoft.Office.Interop.Word.Envelope

    Dim WordApp As New Microsoft.Office.Interop.Word.Application

    AddHandler WordApp.Quit, AddressOf WordOnQuit

    Dim Doc As Microsoft.Office.Interop.Word.Document = WordApp.Documents.Add

    Act = Doc.Envelope

    WordApp.Selection.TypeText("VB.NET Rocks")

    Dim strAddr As String

    Dim strReturnAddr As String

    strAddr = "ADDR" & vbCr & "123 Skye St." & vbCr & "OurTown, WA 98107"

    strReturnAddr = "retADDR" & vbCr & "456 Erde Lane" & vbCr & "OurTown, WA 98107"

    Act.Insert2000(Address:=strAddr, ReturnAddress:=strReturnAddr, Size:="Size 10")

    WordApp.Visible = True

    i want to add more than one envelope in word doc

    Thanks in advance
    • Moved by nobugzMVP, Moderator Wednesday, June 17, 2009 12:09 PM not a wf q (From:Windows Forms General)
    • Edited by srikanth09 Wednesday, June 24, 2009 9:55 AM R&D
    Wednesday, June 17, 2009 7:09 AM


  • Hi srikanth09,

    In one word document, it only supports one envelope.
    If the document is diffent, you may create a new word document and  envelope.
    If you want to merge mails to envelopes, you can record a macro following this article: Then view the macro to see how to do this.

    Best Regards

    Yichun Feng

    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    • Marked as answer by Yichun Feng Tuesday, June 23, 2009 7:41 AM
    Friday, June 19, 2009 6:28 AM