Kbase P99856: Page header incorrectly positioned on page when using VIEW-AS EDITOR fields.
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  1/10/2005 |
|
Status: Unverified
SYMPTOM(s):
Page header incorrectly positioned on page when using VIEW-AS EDITOR fields.
Executing the following code generates a report where the header is correctly positioned on the first page only:
DEFINE VARIABLE iPageSize AS INTEGER NO-UNDO INITIAL 20.
DEFINE FRAME f-head HEADER "This is the header line " AT 1 "Page :" AT 60 PAGE-NUMBER FORMAT ">>9" WITH PAGE-TOP NO-BOX STREAM-IO.
DEFINE FRAME f-item item.itemNum item.itemName VIEW-AS EDITOR SIZE 25 BY 1 WITH DOWN FRAME f-item CENTERED NO-BOX STREAM-IO.
OUTPUT TO "item.out" PAGED PAGE-SIZE VALUE(iPageSize).
VIEW FRAME f-head.
FOR EACH ITEM:
DISPLAY itemNum itemName WITH FRAME f-item.
DOWN WITH FRAME f-item.
END.
CAUSE:
Progress does not handle paging when displaying editor widgets if the data frame is separate from the header frame.
FIX:
The following code exercises direct paging control to explicitly skip to a new page thus ensuring the proper placement of the header frame:
DEFINE VARIABLE iPageSize AS INTEGER NO-UNDO INITIAL 20.
DEFINE FRAME f-head HEADER "Page :" AT 60 PAGE-NUMBER FORMAT ">>9" WITH PAGE-TOP NO-BOX STREAM-IO.
DEFINE FRAME f-item item.itemNum item.itemName VIEW-AS EDITOR SIZE 25 BY 1 WITH DOWN FRAME f-item CENTERED NO-BOX STREAM-IO.
OUTPUT TO "item.out" PAGED PAGE-SIZE VALUE(iPageSize).
VIEW FRAME f-head.
FOR EACH ITEM:
IF LINE-COUNTER = iPageSize THEN PAGE.
DISPLAY itemNum itemName WITH FRAME f-item.
DOWN WITH FRAME f-item.
END.