ADDSection_Propagate
ADDImage_Propagate
ADDImage_Propagate has been replaced with ADDSection_Propagate. ADDImage_Propagate and ADDSection_Propagate have same functionality; the only change is to the function name. The existing ADDImage_Propagate scripts will continue to function and will not require any modification.
Use this procedure/function during GenData processing to add a new section and propagate global data onto the newly added section as needed.
Note | This DAL procedure should only be used with the GenData program. Documaker Desktop users should use the AddSection procedure. If called from Documaker Desktop, this procedure will work exactly like the AddSection procedure. |
Syntax
ADDSection_Propagate (FAP, Section, Form, Group, Flag)
Parameter |
Description |
FAP |
Enter the name of the section file to load and add to the form. |
Section |
Enter the name of a section which will precede the new section. The default is the current section. |
Form |
Enter the name of a form in the form set. If you specify the Section parameter, that section must occur on this form. The default is the current form. |
Group |
Enter the name of a group that contains the specified form. The default is the current group. |
Flag |
Determines if the section is inserted on the same page or on a new page. 0 - new page The default is zero (0). |
Optionally, this procedure returns one (1) on success or zero (0) on failure.
This procedure adds a copy of the section you specify to a form. The system loads the new section onto the page after the section, form, or group you specified or onto a new page which it creates after the section, form, or group you specified. The section added does not have to be predefined for the form.
Keep in mind...
- Global multiline variable field data is not propagated to the added form.
- The system does not move sections already defined for a page. Therefore, you can overlay existing sections on the page.
- Make sure you do not unintentionally overlay an existing section. You can move the new section using the SectionRect and SetSectionPos procedures.
- If you use this procedure to add sections to forms and you also import and export those forms, be sure to set the IgnoreInvalidImage option in the ImpFile_CD control group. Otherwise, users will receive an error message. For detailed instructions, see the Documaker Desktop Administration Guide.
- When adding a section, there is no way for you to specify what section options or recipients you want included on the new section. So, the ADDSection_Propagate procedure takes the missing information from an associated section. The system will, however, exclude the In-lined, Copy on Overflow, Duplex Front, Duplex Back, and Caused by Overflow settings. These options are not normally associated with a section being added via DAL.
Example
Here are some examples:
Procedure |
Result |
Explanation |
ADDSection_Propagate ("IMG1") |
1 - if successfully added 0 - if not added |
Insert the named section, IMG1, on a new page after the current page. |
ADDSection_Propagate("NEW1", "IMG\3",,"GRP") |
1 - if successfully added 0 - if not added |
Insert the named section, NEW1, after the third occurrence of IMG, within GRP. This section is placed on a new page after the third occurrence of the specified section. |
ADDSection_Propagate ("IMG1",,,, 1) |
1 - if successfully added 0 - if not added |
Insert the named section, IMG1, after the current section on the same page. |
ADDSection_Propagate("NEW1", "IMG\3", , , 1) |
1 - if successfully added 0 - if not added |
Insert the named section, NEW1, after the third occurrence of IMG on the same page. |