Help / WLanguage / WLanguage functions / Controls, pages and windows / Word Processing functions
  • Properties specific to the description of docHeaderFooter variables
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Stored procedures
The docHeaderFooter type is used to define the text of the different paragraphs found in a page header or footer. The characteristics of this header or footer can be defined and changed using different WLanguage properties.
CAUTION: This type must not be used directly. It must only be used via docSection variables.
Remark: For more details on the declaration of this type of variable and the use of WLanguage properties, see Declaring a variable.
MyDoc is Document
// Create the page header
s is docSection = MyDoc.Section
s.Header.OddPageInherited = True
d is docFragment(s.Header.FirstPage, 1)
d.Formatting.FontBold = True
d.Formatting.FontSize = 24
d.Text = "HEADER"
MyPara is docParagraph = d.Paragraph[1]
MyPara.PageLayout.Alignment = haCenter
//Insert an image into the header
d3 is docFragment(s.Header.FirstPage, 1)
Img is Image = fExeDir() + "\testimg.jpg"
MyImageElement is docElement
MyImageElement.Type = typeDocElementImage
MyImageElement.Image.BufferImage = Img
MyImageElement.Image.Width = 20
MyImageElement.Image.Height = 20
DocInsert(d3, MyImageElement)
// Create a page footer
sFooter is docSection = MyDoc.Section
dFooter is docFragment(sFooter.Footer.OddPage, 1)
MyPara2 is docParagraph = dFooter.Paragraph[1]
MyPara2.PageLayout.Alignment = haRight
// Insert a formula into the footer
MyFormulaElement is docElement
MyFormulaElement.Type = typeDocElementFormula
MyFormulaElement.Formula.Instruction = "PAGE \* Arabic \* MERGEFORMAT"
DocInsert(dFooter, MyFormulaElement)
WP_NoName1 = MyDoc

Properties specific to the description of docHeaderFooter variables

The following properties can be used to handle a docHeaderFooter variable:
Property nameType usedEffect
ParagraphArray of docParagraphSet of paragraphs making up the page header or footer.
Minimum version required
  • Version 22
This page is also available for…
Click [Add] to post a comment

Last update: 05/26/2022

Send a report | Local help