Put the Output into the Document Container 
At the event handling for previous and next (where you naturally know if the user has requested a different output) and after having produced the form, you need to put that output into the Document Container. Likewise, as we saw for event GC_EVENT_DISPLAY, all you have to do is just putting your output from the report into the Document Container, and the Web Dypro component HRGRT_FC_DOCUMENT_DISPLAY fetches it automatically without you having to tell it.
Example
Code example for sending your form output to the Document Container:
Syntax
data: lv_output_content TYPE xstring.
data: lv_header_text TYPE string.
GO_OUTPUT_CONTAINER->SET_DOCUMENT
(IV_CONTENT = lv_output_content
IV_CONTENT_TYPE = cl_hrgrt_document_container=>gc_doc_type-pdf
IV_HEADER_TEXT = lv_header_text). " set dynamically in code as/req
* set the global index variable for comparison at subsequent event processing
gv_prev_lead_index = cv_lead_index. “ for LIST UIBBs only!!!