Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Description

Excerpt

The WordTemplate object represents a WordWriter template. A WordWriter template is a file created in Microsoft Word that contains merge fields.

Signature
C#
C#
public sealed class WordTemplate
{signature}{signature:
}
Signature
vb.net
vb.net
Public NotInheritable Class WordTemplate
{signature}
{remarks}The {{WordTemplate}} object is in the 
Remarks

The WordTemplate object is in the SoftArtisans.OfficeWriter.WordWriter

namespace.

The

object

can

be

referenced

as

{{

SoftArtisans.WordWriter.WordTemplate

}}

.

To

minimize

typing

and

errors,

import

the

namespace

to

the

aspx

page,

and

reference

the

object

as

{{

WordTemplate

}}

,

without

the

namespace

prefix.

{remarks} {example} If you are coding directly in the .aspx page, following the Page directive, include: {code}

Example

If you are coding directly in the .aspx page, following the Page directive, include:

Code Block

<%@ Import Namespace="SoftArtisans.OfficeWriter.WordWriter" %>
{code}

If

you

are

coding

in

the

"code

behind"

page

\

(.aspx.vb

or

.aspx.cs

\

),

include

an

{{

Imports

}}

or

{{

using

}}

statement

at

the

top

of

the

"code

behind"

page:

{

Code Block
:
csharp
|
csharp
title
=
C#
}

using SoftArtisans.OfficeWriter.WordWriter;
{code} {code:
Code Block
vb.net
|title=
vb.net
titlevb.net
}

Imports SoftArtisans.OfficeWriter.WordWriter
{code}

To

create

an

instance

of

the

WordTemplate

object

use:

{

Code Block
:
csharp
|
csharp
title
=
C#
}

WordTemplate wt = new WordTemplate();
{code} {code:
Code Block
vb.net
|title=
vb.net
titlevb.net
}

Dim wt As New WordTemplate()
{code} {example} {fields} | [
Fields

...

Excerpt Include
WW8:WordTemplate.ALL_ROWS

...

WW8:WordTemplate.ALL_ROWS

...

nopanel

...

true
Properties

Name

Description

Bookmarks

Excerpt Include
WW8:WordTemplate.Bookmarks
WW8:WordTemplate.Bookmarks
nopaneltrue

ContentType

Excerpt Include
WW8:WordTemplate.ContentType
WW8:WordTemplate.ContentType
nopaneltrue

CultureInfo

Excerpt Include
WW8:WordTemplate.CultureInfo
WW8:WordTemplate.CultureInfo
nopaneltrue

DataSourceSeparator

Excerpt Include
WW8:WordTemplate.DataSourceSeparator
WW8:WordTemplate.DataSourceSeparator
nopaneltrue

EnableNEXTFields

Excerpt Include
WW8:WordTemplate.EnableNEXTFields
WW8:WordTemplate.EnableNEXTFields
nopaneltrue

FieldMarkers

Excerpt Include
WW8:WordTemplate.FieldMarkers
WW8:WordTemplate.FieldMarkers
nopaneltrue

LicenseKey

Excerpt Include
WW8:WordTemplate.LicenseKey
WW8:WordTemplate.LicenseKey
nopaneltrue

PreserveFields

Excerpt Include
WW8:WordTemplate.PreserveFields
WW8:WordTemplate.PreserveFields
nopaneltrue

SaveExtension

Excerpt Include
WW8:WordTemplate.SaveExtension
WW8:WordTemplate.SaveExtension
nopaneltrue

UnlinkIfFields

Excerpt Include
WW8:WordTemplate.UnlinkIfFields
WW8:WordTemplate.UnlinkIfFields
nopaneltrue

UpdateIfFields

Excerpt Include
WW8:WordTemplate.UpdateIfFields
WW8:WordTemplate.UpdateIfFields
nopaneltrue

Version

Excerpt Include
WW8:WordTemplate.Version
WW8:WordTemplate.Version
nopaneltrue
Methods

Name

Description

BookmarkFieldMarkers(String)

Excerpt Include
WW8:WordTemplate.BookmarkFieldMarkers(String)
WW8:WordTemplate.BookmarkFieldMarkers(String)
nopaneltrue

Open(String)

Excerpt Include
WW8:WordTemplate.Open(String)
WW8:WordTemplate.Open(String)
nopaneltrue

Open(System.IO.Stream)

...

Excerpt Include
WW8:WordTemplate.Open(System.IO.Stream)

...

WW8:WordTemplate.Open(System.IO.Stream)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.Open(WordApplication,

...

Document)

...

WW8:WordTemplate.Open(WordApplication,

...

Document)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.Process()

...

WW8:WordTemplate.Process()

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.Save(String)

...

WW8:WordTemplate.Save(String)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.Save(System.IO.Stream)

...

WW8:WordTemplate.Save(System.IO.Stream)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.Save(System.Web.HttpResponse)

...

WW8:WordTemplate.Save(System.Web.HttpResponse)

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.Save(System.Web.HttpResponse,

...

String,

...

Boolean)

...

WW8:WordTemplate.Save(System.Web.HttpResponse,

...

String,

...

Boolean)

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(Object(),

...

String(),

...

String)

...

WW8:WordTemplate.SetDataSource(Object(),

...

String(),

...

String)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(Object(),

...

String())

...

WW8:WordTemplate.SetDataSource(Object(),

...

String())

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Data.DataSet,

...

String)

...

WW8:WordTemplate.SetDataSource(System.Data.DataSet,

...

String)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Data.DataSet)

...

WW8:WordTemplate.SetDataSource(System.Data.DataSet)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Data.DataTable,

...

String)

...

WW8:WordTemplate.SetDataSource(System.Data.DataTable,

...

String)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Data.DataTable)

...

WW8:WordTemplate.SetDataSource(System.Data.DataTable)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Data.IDataReader,

...

String)

...

WW8:WordTemplate.SetDataSource(System.Data.IDataReader,

...

String)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Data.IDataReader)

...

WW8:WordTemplate.SetDataSource(System.Data.IDataReader)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(Object,

...

String)

...

WW8:WordTemplate.SetDataSource(Object,

...

String)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Collections.IEnumerator,

...

String())

...

WW8:WordTemplate.SetDataSource(System.Collections.IEnumerator,

...

String())

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Collections.IEnumerator,

...

String(),

...

String)

...

WW8:WordTemplate.SetDataSource(System.Collections.IEnumerator,

...

String(),

...

String)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Collections.IDictionary)

...

WW8:WordTemplate.SetDataSource(System.Collections.IDictionary)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Collections.IDictionary,

...

String)

...

WW8:WordTemplate.SetDataSource(System.Collections.IDictionary,

...

String)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Collections.ICollection,

...

String())

...

WW8:WordTemplate.SetDataSource(System.Collections.ICollection,

...

String())

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetDataSource(System.Collections.ICollection,

...

String(),

...

String)

...

WW8:WordTemplate.SetDataSource(System.Collections.ICollection,

...

String(),

...

String)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(Object(,),

...

String())

...

WW8:WordTemplate.SetMailMerge(Object(,),

...

String())

...

nopanel

...

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(Object(,),

...

String(),

...

Int32,

...

Boolean)

...

WW8:WordTemplate.SetMailMerge(Object(,),

...

String(),

...

Int32,

...

Boolean)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(Object(),

...

String())

...

WW8:WordTemplate.SetMailMerge(Object(),

...

String())

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(Object()(),

...

String())

...

WW8:WordTemplate.SetMailMerge(Object()(),

...

String())

...

nopanel

...

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(Object()(),

...

String(),

...

Int32,

...

Boolean)

...

WW8:WordTemplate.SetMailMerge(Object()(),

...

String(),

...

Int32,

...

Boolean)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(System.Collections.ICollection)

...

WW8:WordTemplate.SetMailMerge(System.Collections.ICollection)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(System.Collections.IEnumerator)

...

WW8:WordTemplate.SetMailMerge(System.Collections.IEnumerator)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(System.Data.DataSet)

...

WW8:WordTemplate.SetMailMerge(System.Data.DataSet)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(System.Data.DataSet,

...

Int32)

...

WW8:WordTemplate.SetMailMerge(System.Data.DataSet,

...

Int32)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(System.Data.DataTable)

...

WW8:WordTemplate.SetMailMerge(System.Data.DataTable)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(System.Data.DataTable,

...

Int32)

...

WW8:WordTemplate.SetMailMerge(System.Data.DataTable,

...

Int32)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(System.Data.IDataReader)

...

WW8:WordTemplate.SetMailMerge(System.Data.IDataReader)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetMailMerge(System.Data.IDataReader,

...

Int32)

...

WW8:WordTemplate.SetMailMerge(System.Data.IDataReader,

...

Int32)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(System.Data.DataSet,

...

String)

...

WW8:WordTemplate.SetRepeatBlock(System.Data.DataSet,

...

String)

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(System.Data.DataSet,

...

String,

...

Int32)

...

WW8:WordTemplate.SetRepeatBlock(System.Data.DataSet,

...

String,

...

Int32)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(System.Data.DataTable,

...

String)

...

WW8:WordTemplate.SetRepeatBlock(System.Data.DataTable,

...

String)

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(System.Data.DataTable,

...

String,

...

Int32)

...

WW8:WordTemplate.SetRepeatBlock(System.Data.DataTable,

...

String,

...

Int32)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(System.Data.IDataReader,

...

String)

...

WW8:WordTemplate.SetRepeatBlock(System.Data.IDataReader,

...

String)

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(System.Data.IDataReader,

...

String,

...

Int32)

...

WW8:WordTemplate.SetRepeatBlock(System.Data.IDataReader,

...

String,

...

Int32)

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(Object(),

...

String(),

...

String)

...

WW8:WordTemplate.SetRepeatBlock(Object(),

...

String(),

...

String)

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(Object(,),

...

String(),

...

String)

...

WW8:WordTemplate.SetRepeatBlock(Object(,),

...

String(),

...

String)

...

nopanel

...

...

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(Object(,),

...

String(),

...

String,

...

Int32,

...

Boolean)

...

WW8:WordTemplate.SetRepeatBlock(Object(,),

...

String(),

...

String,

...

Int32,

...

Boolean)

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(Object()(),

...

String(),

...

String)

...

WW8:WordTemplate.SetRepeatBlock(Object()(),

...

String(),

...

String)

...

nopanel

...

...

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(Object()(),

...

String(),

...

String,

...

Int32,

...

Boolean)

...

WW8:WordTemplate.SetRepeatBlock(Object()(),

...

String(),

...

String,

...

Int32,

...

Boolean)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(System.Collections.IEnumerator,

...

String)

...

WW8:WordTemplate.SetRepeatBlock(System.Collections.IEnumerator,

...

String)

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(System.Collections.IEnumerator,

...

String,

...

String)

...

WW8:WordTemplate.SetRepeatBlock(System.Collections.IEnumerator,

...

String,

...

String)

...

nopanel

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(System.Collections.ICollection,

...

String)

...

WW8:WordTemplate.SetRepeatBlock(System.Collections.ICollection,

...

String)

...

nopanel

...

...

...

...

Excerpt Include
WW8:WordTemplate.SetRepeatBlock(System.Collections.ICollection,

...

String,

...

String)

...

WW8:WordTemplate.SetRepeatBlock(System.Collections.ICollection,

...

String,

...

String)

...

nopanel

...

...

Excerpt Include
WW8:WordTemplate.WordTemplate()

...

WW8:WordTemplate.WordTemplate()

...

nopanel

...

true
Extensionmethods
Introducedin
4.5
4.5

...

...

Excerpt Include
WW8:SharePointIntegration.Open(WordTemplate,

...

Microsoft.SharePoint.SPDocumentLibrary,

...

String)

...

WW8:SharePointIntegration.Open(WordTemplate,

...

Microsoft.SharePoint.SPDocumentLibrary,

...

String)

...

nopanel

...

...

...

Excerpt Include
WW8:SharePointIntegration.Open(WordTemplate,

...

Microsoft.SharePoint.SPListItem,

...

String)

...

WW8:SharePointIntegration.Open(WordTemplate,

...

Microsoft.SharePoint.SPListItem,

...

String)

...

nopanel

...

...

...

...

Excerpt Include
WW8:SharePointIntegration.Save(WordTemplate,

...

Microsoft.SharePoint.SPDocumentLibrary,

...

String,

...

Boolean)

...

WW8:SharePointIntegration.Save(WordTemplate,

...

Microsoft.SharePoint.SPDocumentLibrary,

...

String,

...

Boolean)

...

nopanel

...

...

...

Excerpt Include
WW8:SharePointIntegration.Save(WordTemplate,

...

Microsoft.SharePoint.SPListItem,

...

String)

...

WW8:SharePointIntegration.Save(WordTemplate,

...

Microsoft.SharePoint.SPListItem,

...

String)

...

nopanel

...

...

...

Excerpt Include
WW8:SharePointIntegration.SetDataSource(WordTemplate,

...

Microsoft.SharePoint.SPList,

...

String)

...

WW8:SharePointIntegration.SetDataSource(WordTemplate,

...

Microsoft.SharePoint.SPList,

...

String)

...

nopanel

...

...

Excerpt Include
WW8:SharePointIntegration.SetDataSource(WordTemplate,

...

Microsoft.SharePoint.SPList)

...

WW8:SharePointIntegration.SetDataSource(WordTemplate,

...

Microsoft.SharePoint.SPList)

...

nopanel

...

...

...

...

Excerpt Include
WW8:SharePointIntegration.SetDataSource(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList,

...

String)

...

WW8:SharePointIntegration.SetDataSource(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList,

...

String)

...

nopanel

...

...

...

Excerpt Include
WW8:SharePointIntegration.SetDataSource(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList)

...

WW8:SharePointIntegration.SetDataSource(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList)

...

nopanel

...

...

...

Excerpt Include
WW8:SharePointIntegration.SetMailMerge(WordTemplate,

...

Microsoft.SharePoint.SPList,

...

Int32)

...

WW8:SharePointIntegration.SetMailMerge(WordTemplate,

...

Microsoft.SharePoint.SPList,

...

Int32)

...

nopanel

...

...

Excerpt Include
WW8:SharePointIntegration.SetMailMerge(WordTemplate,

...

Microsoft.SharePoint.SPList)

...

WW8:SharePointIntegration.SetMailMerge(WordTemplate,

...

Microsoft.SharePoint.SPList)

...

nopanel

...

...

...

...

Excerpt Include
WW8:SharePointIntegration.SetMailMerge(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList,

...

Int32)

...

WW8:SharePointIntegration.SetMailMerge(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList,

...

Int32)

...

nopanel

...

...

...

Excerpt Include
WW8:SharePointIntegration.SetMailMerge(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList)

...

WW8:SharePointIntegration.SetMailMerge(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList)

...

nopanel

...

...

...

...

Excerpt Include
WW8:SharePointIntegration.SetRepeatBlock(WordTemplate,

...

Microsoft.SharePoint.SPList,

...

String,

...

Int32)

...

WW8:SharePointIntegration.SetRepeatBlock(WordTemplate,

...

Microsoft.SharePoint.SPList,

...

String,

...

Int32)

...

nopanel

...

...

...

Excerpt Include
WW8:SharePointIntegration.SetRepeatBlock(WordTemplate,

...

Microsoft.SharePoint.SPList,

...

String)

...

WW8:SharePointIntegration.SetRepeatBlock(WordTemplate,

...

Microsoft.SharePoint.SPList,

...

String)

...

nopanel

...

...

...

...

...

Excerpt Include
WW8:SharePointIntegration.SetRepeatBlock(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList,

...

String,

...

Int32)

...

WW8:SharePointIntegration.SetRepeatBlock(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList,

...

String,

...

Int32)

...

nopanel

...

...

...

...

Excerpt Include
WW8:SharePointIntegration.SetRepeatBlock(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList,

...

String)

...

WW8:SharePointIntegration.SetRepeatBlock(WordTemplate,

...

Microsoft.SharePoint.SPView,

...

Microsoft.SharePoint.SPList,

...

String)

...

nopanel

...

true

...