Modifica

Condividi tramite


_Document.CreateLetterContent Method

Definition

Creates and returns a LetterContent object based on the specified letter elements.

public Microsoft.Office.Interop.Word.LetterContent CreateLetterContent (string DateFormat, bool IncludeHeaderFooter, string PageDesign, Microsoft.Office.Interop.Word.WdLetterStyle LetterStyle, bool Letterhead, Microsoft.Office.Interop.Word.WdLetterheadLocation LetterheadLocation, float LetterheadSize, string RecipientName, string RecipientAddress, string Salutation, Microsoft.Office.Interop.Word.WdSalutationType SalutationType, string RecipientReference, string MailingInstructions, string AttentionLine, string Subject, string CCList, string ReturnAddress, string SenderName, string Closing, string SenderCompany, string SenderJobTitle, string SenderInitials, int EnclosureNumber, ref object InfoBlock, ref object RecipientCode, ref object RecipientGender, ref object ReturnAddressShortForm, ref object SenderCity, ref object SenderCode, ref object SenderGender, ref object SenderReference);
abstract member CreateLetterContent : string * bool * string * Microsoft.Office.Interop.Word.WdLetterStyle * bool * Microsoft.Office.Interop.Word.WdLetterheadLocation * single * string * string * string * Microsoft.Office.Interop.Word.WdSalutationType * string * string * string * string * string * string * string * string * string * string * string * int * obj * obj * obj * obj * obj * obj * obj * obj -> Microsoft.Office.Interop.Word.LetterContent
Public Function CreateLetterContent (DateFormat As String, IncludeHeaderFooter As Boolean, PageDesign As String, LetterStyle As WdLetterStyle, Letterhead As Boolean, LetterheadLocation As WdLetterheadLocation, LetterheadSize As Single, RecipientName As String, RecipientAddress As String, Salutation As String, SalutationType As WdSalutationType, RecipientReference As String, MailingInstructions As String, AttentionLine As String, Subject As String, CCList As String, ReturnAddress As String, SenderName As String, Closing As String, SenderCompany As String, SenderJobTitle As String, SenderInitials As String, EnclosureNumber As Integer, Optional ByRef InfoBlock As Object, Optional ByRef RecipientCode As Object, Optional ByRef RecipientGender As Object, Optional ByRef ReturnAddressShortForm As Object, Optional ByRef SenderCity As Object, Optional ByRef SenderCode As Object, Optional ByRef SenderGender As Object, Optional ByRef SenderReference As Object) As LetterContent

Parameters

DateFormat
String

Required String. The date for the letter.

IncludeHeaderFooter
Boolean

Required Boolean. True to include the header and footer from the page design template.

PageDesign
String

Required String. The name of the template attached to the document.

LetterStyle
WdLetterStyle

Required WdLetterStyle. The document layout.

Letterhead
Boolean

Required Boolean. True to reserve space for a preprinted letterhead.

LetterheadLocation
WdLetterheadLocation

Required WdLetterheadLocation. The location of the preprinted letterhead.

LetterheadSize
Single

Required Single. The amount of space (in points) to be reserved for a preprinted letterhead.

RecipientName
String

Required String. The name of the person who'll be receiving the letter.

RecipientAddress
String

Required String. The mailing address of the person who'll be receiving the letter.

Salutation
String

Required String. The salutation text for the letter.

SalutationType
WdSalutationType

Required WdSalutationType. The salutation type for the letter.

RecipientReference
String

Required String. The reference line text for the letter (for example, "In reply to:").

MailingInstructions
String

Required String. The mailing instruction text for the letter (for example, "Certified Mail").

AttentionLine
String

Required String. The attention line text for the letter (for example, "Attention:").

Subject
String

Required String. The subject text for the specified letter.

CCList
String

Required String. The names of the carbon copy (CC) recipients for the letter.

ReturnAddress
String

Required String. The text of the return mailing address for the letter.

SenderName
String

Required String. The name of the person sending the letter.

Closing
String

Required String. The closing text for the letter.

SenderCompany
String

Required String. The company name of the person creating the letter.

SenderJobTitle
String

Required String. The job title of the person creating the letter.

SenderInitials
String

Required String. The initials of the person creating the letter.

EnclosureNumber
Int32

Required Integer. The number of enclosures for the letter.

InfoBlock
Object

Optional Object. This argument may not be available to you, depending on the language support (U.S. English, for example) that you’ve selected or installed.

RecipientCode
Object

Optional Object. This argument may not be available to you, depending on the language support (U.S. English, for example) that you’ve selected or installed.

RecipientGender
Object

Optional Object. This argument may not be available to you, depending on the language support (U.S. English, for example) that you’ve selected or installed.

ReturnAddressShortForm
Object

Optional Object. This argument may not be available to you, depending on the language support (U.S. English, for example) that you’ve selected or installed.

SenderCity
Object

Optional Object. This argument may not be available to you, depending on the language support (U.S. English, for example) that you’ve selected or installed.

SenderCode
Object

Optional Object. This argument may not be available to you, depending on the language support (U.S. English, for example) that you’ve selected or installed.

SenderGender
Object

Optional Object. This argument may not be available to you, depending on the language support (U.S. English, for example) that you’ve selected or installed.

SenderReference
Object

Optional Object. This argument may not be available to you, depending on the language support (U.S. English, for example) that you’ve selected or installed.

Returns

Applies to