Highlighted

Imported element definitions from EDD don't show in template

Explorer ,
Oct 17, 2017

Copy link to clipboard

Copied

I followed instructions from another thread to import elements from my EDD to a template, but it didn't work. Only one of the elements from the EDD shows up.

I opened both the template and the EDD, then used File > Import > Element Definitions to bring the element definitions into the template file.

The "chapter" element is the only element I see.

I'm using FrameMaker 10. Not sure what I'm missing in this process.

This looks correct for a structured template with one top level element defined. It is exactly what you need if you are using this template in a structured XML application.

When an XML file is imported it will populate a copy of this template with the structure from the XML. <chapter> will be the root element.

If, on the other hand you are creating new content in a structured FrameMaker document, the chapter element must be added to the document like this:

  1. Select 'chapter' in the ELEMENTS catalog pod.
  2. Click Insert. A new root element will be created which will be visible in the STRUCTURE VIEW pod. You will now see the valid child elements in the ELEMENTS catalog pod.

Note, you can select Options... to change the elements visible in the ELEMENTS catalog pod so that you can see all possible elements if preferred.

I hope that helps?

Ian

TOPICS
Structured

Views

458

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Imported element definitions from EDD don't show in template

Explorer ,
Oct 17, 2017

Copy link to clipboard

Copied

I followed instructions from another thread to import elements from my EDD to a template, but it didn't work. Only one of the elements from the EDD shows up.

I opened both the template and the EDD, then used File > Import > Element Definitions to bring the element definitions into the template file.

The "chapter" element is the only element I see.

I'm using FrameMaker 10. Not sure what I'm missing in this process.

This looks correct for a structured template with one top level element defined. It is exactly what you need if you are using this template in a structured XML application.

When an XML file is imported it will populate a copy of this template with the structure from the XML. <chapter> will be the root element.

If, on the other hand you are creating new content in a structured FrameMaker document, the chapter element must be added to the document like this:

  1. Select 'chapter' in the ELEMENTS catalog pod.
  2. Click Insert. A new root element will be created which will be visible in the STRUCTURE VIEW pod. You will now see the valid child elements in the ELEMENTS catalog pod.

Note, you can select Options... to change the elements visible in the ELEMENTS catalog pod so that you can see all possible elements if preferred.

I hope that helps?

Ian

TOPICS
Structured

Views

459

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Oct 17, 2017 0
Adobe Community Professional ,
Oct 17, 2017

Copy link to clipboard

Copied

Ted,

   It is almost impossible to guess what might have gone wrong without seeing your EDD. Did you get any error messages when you imported element definitions?

     --Lynne

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 17, 2017 0
Explorer ,
Oct 17, 2017

Copy link to clipboard

Copied

I don't see an option to attach files, but I can copy and paste the EDD.

Structured Application:

Element (Container): chapter

Valid as the highest-level element.

General rule: title | section* | body* | figure* | table* | list* | alert*

Attribute list

Name: language String Optional

Default: English

Element (Container): section

General rule: title | subsection* | body* | figure* | table* | list* | alert*

Element (Container): subsection

General rule: title | body* | figure* | table* | list* | alert*

Element (Container): title

General rule: <TEXT>

Element (Container): body

General rule: <TEXT>

Element (Container): figure

General rule: img, caption

Element (Container): img

General rule: <EMPTY>

Attribute list

Name: src String Required

Element (Container): caption

General rule: <TEXT>

Element (Container): list

General rule: li

Element (Container): li

General rule: <TEXT>

Element (Container): alert

General rule: <TEXT>

Attribute list

Name: type Choice Optional

Choices: warning | caution | important | note

Default: warning

Element (Container): table

General rule: caption, tblHeadRow, tblRow+

Element (Container): tblHeadRow

General rule: tblData+

Element (Container): tblRow

General rule: tblData+

Element (Container): tblData

General rule: <TEXT>

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 17, 2017 0
Enthusiast ,
Oct 17, 2017

Copy link to clipboard

Copied

This looks correct for a structured template with one top level element defined. It is exactly what you need if you are using this template in a structured XML application.

When an XML file is imported it will populate a copy of this template with the structure from the XML. <chapter> will be the root element.

If, on the other hand you are creating new content in a structured FrameMaker document, the chapter element must be added to the document like this:

  1. Select 'chapter' in the ELEMENTS catalog pod.
  2. Click Insert. A new root element will be created which will be visible in the STRUCTURE VIEW pod. You will now see the valid child elements in the ELEMENTS catalog pod.

Note, you can select Options... to change the elements visible in the ELEMENTS catalog pod so that you can see all possible elements if preferred.

I hope that helps?

Ian

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 17, 2017 0
Explorer ,
Oct 17, 2017

Copy link to clipboard

Copied

Okay, the elements are imported, I just couldn't see them. Still trying to sort out how all of this works.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 17, 2017 0
Adobe Community Professional ,
Oct 17, 2017

Copy link to clipboard

Copied

Ted,

1. Despite Ian's comment that your screen capture looks correct, it does show one problem. The Element Catalog window lists the chapter element, but the element tag is not preceded by a checkmark. That indicates that chapter is defined but not permitted at the current location in the document. Is your template empty or does it have existing content? By the way, note that there are four buttons at the bottom of the Element Catalog window (not shown in your screen shot). The Options button brings up the Set Available Elements dialog box (as does the Element > Set Available Elements command). I suspect your document has Show Tags For set to Elements Allowed Anywhere in Parent. You might try the different options and see which one you prefer in various situations.

2. There are various problems with your EDD:

a. Your general rule for chapter is "title | section* | body* | figure* | table* | list* | alert*" which defines a chapter to be a title, zero or more sections, zero or more body elements, or zero or more of any of the other listed elements. It does not allow a chapter to contain different element types. For example, if there is a title no other elements are allowed. You probably want something like "title, (body | figure | table | list | alert)*, section*" which requires a chapter to start with a title that is then followed by any number of body, figure, table, list, and alert elements in any order, which in turn are optionally followed by sections. Nothing after the title is required. There are more complicated expressions that require at least one element after the title. There are parallel problems with the definitions of section and subsection.

b. You've defined img to be a container. I suspect you want it to be a graphic with the required src attribute to name the graphics file you want to import. If so, you should define the element to be a Graphic and not use the attribute. If, as Ian suggested might be the case, you are moving content between FrameMaker and XML, you can define the src attribute in XML only. In such case, you can use read/write rules to specify that img is a Graphic element and map the name of the file imported into FrameMaker to the value of the XML src attribute.

c. Presumably, your table element is used for tables. If so, you need to define it to be a Table rather than a Container; tblHeadRow and tblRow would then be  TableRows and tblData would be a TableCell. Furthermore, FrameMaker requires all table heading rows (even if there is only one) to be grouped into a table heading element and all table body rows to be grouped into a table body element. Thus your general rule for Table should be something like caption, tblHeading, tblBody where tblHeading is a TableHeading with a general rule such as tblHeadRow+ and tblBody is a TableBody with a general rule such as tblRow+. (You might instead use tblRow for both heading and body rows.) One further complication is that if you use caption for the title of a table, you'll need to define it to be a TableTitle rather than a Container. Furthermore, unless you make Figure a Table, you won't be able to use caption for both the title of a table and that of a figure.

--Lynne

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 17, 2017 0
Explorer ,
Oct 19, 2017

Copy link to clipboard

Copied

I have updated the EDD, and I can generate a DTD from it without any errors happening. However, when I attempt to import the element definitions, I get an error message:

EDD Version is 10.0

Structured Application:

Element (Container): Chapter

Valid as the highest-level element.

General rule: Title, (Body | Figure | Table | List | Alert)*, Section*

Attribute list

Name: Language String Optional

Default: English

Name: Id Unique ID Optional

Element (Container): Section

General rule: Title, (Body | Figure | Table | List | Alert)*, Subsection*

Attribute list

Name: Id Unique ID Optional

Element (Container): Subsection

General rule: Title, (Body | Figure | Table | List | Alert)*

Attribute list

Name: Id Unique ID Optional

Element (Container): Title

General rule: <TEXT>

Element (Container): Body

General rule: Paragraph+

Element (Container): Figure

General rule: Graphic, Caption?

Attribute list

Name: Id Unique ID Optional

Element (Container): Caption

General rule: <TEXT>

Element (Container): List

General rule: Item+

Element (Container): Item

General rule: <TEXT>

Element (Container): Alert

General rule: Paragraph+

Attribute list

Name: Type Choice Optional

Choices: Warning | Caution | Important | Note

Default: Warning

Element (Container): Table

General rule: TableHead?, TableBody

Attribute list

Name: Id Unique ID Optional

Element (Container): TableHead

General rule: Row+

Element (Container): TableBody

General rule: Row+

Element (Table Row): Row

General rule: Cell+

Element (Container): Cell

General rule: Paragraph?, Graphic?

Element (Graphic): Graphic

Element (Container): Paragraph

General rule: (<TEXT> | List | Xref)*

Element (CrossReference): Xref

Attribute list

Name: Idref ID Reference Required

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 19, 2017 0
Adobe Community Professional ,
Oct 19, 2017

Copy link to clipboard

Copied

Ted,

   Your EDD defines Cell to be a Container and Row to be a TableRow. It also defines Row to consist of Cells. The error message means that Cell is the wrong type of element to occur in Row. The error message is correct because TableRow elements can only contain TableCell elements.

       --Lynne

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 19, 2017 1
Explorer ,
Oct 19, 2017

Copy link to clipboard

Copied

Got it. Successful import.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 19, 2017 0
Explorer ,
Oct 20, 2017

Copy link to clipboard

Copied

Not sure why FM won't let me insert Row elements.

Element (Container): Table

General rule: TableHead*, TableBody

Attribute list

Name: Id Unique ID Optional

Element (Table Heading): TableHead

General rule: Row+

Element (Table Body): TableBody

General rule: Row+

Element (Table Row): Row

General rule: Cell+

Element (Table Cell): Cell

General rule: Paragraph*, Graphic*

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 20, 2017 0
Adobe Community Professional ,
Oct 20, 2017

Copy link to clipboard

Copied

Ted,

   The EDD fragment you've included still shows Table defined to be a Container instead of a Table. Do the following:

1. In the EDD, change Table to a Table.

2. Import element definitions from the EDD into the document.

3. Delete the existing Table element and insert a new one. FrameMaker will prompt for the number of heading rows, number of body rows, number of columns, and table format to use. When you insert the table, FrameMaker will insert all required elements for the table.

     --Lynne

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 20, 2017 1
Explorer ,
Oct 20, 2017

Copy link to clipboard

Copied

FM added a Title element to the Table. Is that normal?

Element (Table): Table

General rule: TableHead?, TableBody+

Element (Table Heading): TableHead

General rule: Row+

Element (Table Body): TableBody

General rule: Row+

Element (Table Row): Row

General rule: Cell+

Element (Table Cell): Cell

General rule: Paragraph*, Graphic*

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 20, 2017 0
Adobe Community Professional ,
Oct 20, 2017

Copy link to clipboard

Copied

Ted,

    Whether or not a new table has a title depends on the table format used to create it. In a structured document, if the general rule for the table element (Table in your case) includes a table title element, FrameMaker uses that element. If the general rule does not allow a table title element, FrameMaker uses TITLE for the element tag. If there is no element definition for TITLE, it appears in red in the Structure View.

  To remove a table title element, instead of selecting the element and deleting it, use the table designer to set the Table property to No Title. To add a table title, instead of inserting the element, use the table designer. If none of your tables will have titles, edit one particular table to change the setting, and click the Update Style button to update the table format in the table catalog. Future tables you create will use the updated style and won't have titles.

--Lynne

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 20, 2017 0