Narrative
A layout defines the graphical layout of a letter. The
layout can contain typical form fields such as “Address” and "Reference
Number". It also contains empty subforms that denote target areas.
When the layout is complete, the Application Specialist uploads
it to the Correspondence Management Solution Accelerator. From there,
you can select the layout when creating a correspondence template.
Application Specialists will map content such as text and images
into the target areas, and bind form fields to data sources.
Application Specialists can use one layout to create many different
correspondence templates.
The following picture shows a typical layout created in LiveCycle
Designer 9.
Estimated time to implement the story
The amount of time required to implement this story depends
on the complexity and number of layouts.
Common questions to ask to clarify requirements
Not applicable to this user story.
Requirements addressed
Not applicable to this user story.
Implementation overview
Follow these steps to set create layouts for the Correspondence
Management Solution Accelerator:
-
Look at the existing correspondence that your organization
creates. Decide how many different layouts you will require, and
what those layouts will include. You may be able to use one very
simple layout for all of your correspondence, or you may require
specialized layouts to meet particular needs. (See
Analyzing your existing correspondence
.) For example, in the solution template,
the Notice of Reinstatement and Notice of Cancellation both use
the same layout. (See
Using the Solution Accelerator
.)
-
Create the layout in LiveCycle Designer 9. The layout can
contain typical form fields such as “Address” and "Reference Number".
It also contains empty subforms that denote target areas. For Correspondence
Management-specific details, see “Creating a layout for Correspondence
Management” later in this story. For general information on using
LiveCycle Designer 9, see the
LiveCycle Designer ES2 Help
.
-
Use the Manage Assets UI to upload the layout to the Correspondence Management
system. (See
Working with layouts
.)
Team members
The Form Designer performs the tasks described in this
user story. The Forms Designer should have in-depth knowledge of
LiveCycle Designer 9.
Creating a layout for Correspondence Management
This section contains Correspondence Management-specific
information about how to create a layout.
Target version
You must use LiveCycle Designer 9 to create layouts, and
the layouts must target XFA 2.8 or later. To ensure that your layout
is using the correct target version:
-
In LiveCycle Designer 9, click File > Form Properties
> Defaults, and set the Target Version to Acrobat/Reader 9.0.
-
Go to the XML Source view and confirm that the template version
is 2.8. The
<template>
node should look like
this:
<template xmlns="http://www.xfa.org/schema/xfa-template/2.8/">
-
In the template node, search for
originalXFA node
and
if it is present, delete it. The string would look something like
this:
<?originalXFAVersion http://www.xfa.org/schema/xfa-template/2.6/?>
-
Apply any changes to the XML Source by switching to another
view.
Creating target area subforms
By default, all subforms that are empty of content are
considered target areas. If your layout contains an empty subform
that should not be considered a target area, name the subforms with
an "_int" (internal) suffix; for example, subformWithScript_int.
You may want to use an empty subform as a fragment, containing only
a series of script objects that are used in various forms. In this case,
the subform will appear empty, but should not be considered a target
area. Nodes that are considered to be content are:
area, draw, exclGroup, exObject, field, subform
,
and
subformSet
.
A target area subform should:
A target area subform
must
not:
-
have a binding (set binding as "none")
-
contain content (child nodes of type area, draw, exclGroup,
exObject, field, subform, or subformSet)
-
include an "_int" suffix in its name
-
be located on a master page
Creating relatable fields
By default, all fields are considered relatable to various
other data sources. If your layout contains any fields that should
not be relatable to a data source, name the field with an "_int"
(internal) suffix; for example, pageCount_int.
A relatable field must:
-
be an XFA
<field>
or
<exclGroup>
-
have an XFA binding reference
-
if it is an
<exclGroup>
, it must have
at least one child radio button field; otherwise, its value type
cannot be determined
A relatable field should:
A relatable field must not:
-
include an "_int" suffix in its name
-
have binding set as "none"
-
be a child of an
<exclGroup>
element
As long as a relatable field meets the criteria described above,
it can be in any location and at any nesting depth in the layout.
You can use relatable fields within master pages.
Fields are more flexible in their layout configuration than target
area subforms; however they are tied to a single value type. You
can make a field very big, or set it to a fixed width and height,
and so on. The resolved module or rule result will be pushed into
the field.
Deciding when to use subforms and text fields
Use a subform if you want to capture multiple module content
in a top-down vertical-flow layout (multiple paragraphs and/or images).
Your layout must handle the fact that the subform will grow in height
to accommodate its contents. If you cannot be certain that the length
of the content associated to the subform/target will never exceed
the space reserved for the subform in the layout, you should create
the subform as a child within a flowed subform container. This ensures
that layout objects below the subform will flow downward as the
subform grows.
Use a field if you want to capture module data or data dictionary
element data into your layout's schema (because fields are bound
to data) and/or you need to display module content on a master page.
Remember that content in a master page cannot flow with body page
content, so you must ensure that the image field used as a header
logo, for example, is set to constrain the image content to its
content area, rather than display the image content at its original
size. Otherwise, for a large image, the image may be displayed beneath
body page content.
This table provides more criteria for deciding when to use a
subform or a field in a layout.
Use a subform when
|
Use a text field when
|
It will contain a combination of elements, such
as a Last Name and First Name
|
It will contain a single element, such as
a Policy Number.
|
It will include multiple paragraphs
|
Text should be wrapped and justified
|
Repeating, optional, and conditional data groups
are bound to subforms. This reduces the risk of design errors that could
occur if scripts are used to achieve the same results
|
Elements such as your organization’s logo
and address should appear on all pages of a letter. In this case,
create form fields for those elements and place them on the master
page. If you set the field binding to "No Data Binding", the fields
will not appear as relatable fields in the Letter Editor. If you
want to relate some type of content to these fields, they must have
binding.
If your company address contains more than one line
of data, use two text fields with the "Allow Multiple Lines" option
to represent the address on the layout.
If a text field's
data type is set to plain text, the plain text version of the module output
will be used instead of the rich text version (all formatting will
be discarded). To preserve the formatting, set the text field’s
data type to rich text.
|
Text should be flowed
|
Text fields and image fields are used on
master pages. Master pages cannot use subforms as target areas.
|
Objects are grouped and organized without
binding the subform to a data element
|
|
There is a text field inside the subform. The
subform can grow and not overwrite other objects below it on the
layout.
|
|
Setting up repetitive elements
When elements such as your organization’s logo and address
should appear on all pages of a letter, create form fields for those
elements and place them on the master page. Use Name (Field Name)
binding for these fields.
Specify the server render format
You must set the layout’s server render format to Dynamic
XML Form; otherwise, any letters based on this layout will not render
correctly. By default, the server render format in LiveCycle Designer
9 is set to Dynamic XML Form. To ensure that you are using the correct
format:
In LiveCycle Designer 9, click File > Form Properties
> Defaults, and ensure that the PDF Render/Format setting is
set to Dynamic XML Form.
Best practices/tips and tricks
Set the default subform binding
When
creating target areas in LiveCycle Designer 9, it helps to set the
default binding for all new subforms to "none". To set the default
binding:
-
In LiveCycle Designer 9, click Tools >
Options > Data Bindings > Subform Binding.
-
In the Default Binding for New Subforms list, select No Data
Binding.
This ensures that subforms inserted using the Insert
> Subform command or by dragging and dropping from the Object
Palette will have a binding of "none" by default. This means that
by default, any new subform will be a target area unless you add
content to it, change its binding setting, or name the subform with
an "_int" suffix.
Section 508-compliance
If the finished
letter created in the Create Correspondence UI will be used for filling
in a later workflow, you should follow these recommendations related
to Section 508 when creating the layout. Otherwise, the letter PDF
will just be for display, and you can disregard these recommendations:
-
All target area subforms and all fields in a layout should
have a tab order.
-
Fields with captions are 508-compliant by default. The field’s
/field/assist/speak@priority
attribute
is set to "custom" by default, which means that, unless custom screen
reader text is supplied, the field's caption will be read by the
screen reader.
-
Fields without captions should specify a tooltip and indicate
that screen readers should read the tooltip by setting
/field/assist/speak@priority="toolTip"
and
specifying tooltip text in
/field/assist/toolTip
.
Capturing date ranges
When dealing with
a combination of dates, such as startDate - endDate, use a single
subform to ensure correct alignment in the finished letter, and
to minimize the number of fields.
Setting form-level binding
When a layout
contains many fields and target areas that are mapped to single XML
elements, use form-level binding and create a separate node for
each element. Fields that are bound at the form level should be
ignored when mapping data in Correspondence Management.
Do not use subform target areas in a master page
Subform
targets areas in a master page are not visible in the Manage Assets
UI and data cannot be mapped to them. Instead, use form fields in
master pages.
Choosing appropriate positions and types for target areas
When designing the layout, take care when choosing
subforms. If the layout contains a single subform, it can be a flowed
type. After you position fields in the subform, you can wrap it
in another subform so that the wrapped subform is also flowed and
the layout will not be disturbed.
Layout editing rules
The following rules
apply when using the UI to upload layouts:
-
Addition of variable:
Not
applicable
-
Removal of variable:
Not applicable
-
Updating of properties:
Allowed
-
Change of data dictionary:
Not applicable
-
Addition of layout fields:
Allowed
-
Removal of layout fields:
Not allowed
|
|
|