<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Printing data from table control in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009560#M711183</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi guys,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a requirement where im asked to print data from the table control onto the printer. Any body who has got this kind of requirement earlier or has dealt with these kind of issues, need your valuable ideas on this. This is a bit urgent for me.&lt;/P&gt;&lt;P&gt;Im using a dialog program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Venkat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 05 Nov 2007 14:48:39 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-11-05T14:48:39Z</dc:date>
    <item>
      <title>Printing data from table control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009560#M711183</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi guys,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a requirement where im asked to print data from the table control onto the printer. Any body who has got this kind of requirement earlier or has dealt with these kind of issues, need your valuable ideas on this. This is a bit urgent for me.&lt;/P&gt;&lt;P&gt;Im using a dialog program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Venkat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 14:48:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009560#M711183</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T14:48:39Z</dc:date>
    </item>
    <item>
      <title>Re: Printing data from table control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009561#M711184</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try with this FM : FITRV_PRINT_TABLE_CONTROL_DATA&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

  DATA: pgm LIKE sy-repid,
        tc  TYPE cxtab_control.
 
  pgm = sy-repid.
  tc  = table_control. " Your table control name
 
  CALL FUNCTION 'FITRV_PRINT_TABLE_CONTROL_DATA'
    EXPORTING
      table_control                  = tc   
      callback_program               = pgm
      callback_top_of_list           = 'PRINT_TRIP_HEADER'   " Make this perform for header
      get_curr_quan_fields_from_ddic = ddic_fields  " pass blank 
      optimize_column_width          = optimize      "pass blank
      window_title                   = title             " pass blank
    TABLES
      print_data                     = ptab   " your data tab
    EXCEPTIONS
      column_information_missing     = 1
      printing_not_possible          = 2
      OTHERS                         = 3.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh Patel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 14:52:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009561#M711184</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2007-11-05T14:52:49Z</dc:date>
    </item>
    <item>
      <title>Re: Printing data from table control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009562#M711185</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI Nimesh,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This looks ok and works well, but the problem is its not printing the header data, all the headings its leaving that place as blank. Do you have any suggestion for this. This is the code is used.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: pgm LIKE sy-repid,&lt;/P&gt;&lt;P&gt;        tc  TYPE cxtab_control.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  pgm = sy-repid.&lt;/P&gt;&lt;P&gt;  tc  = tab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'FITRV_PRINT_TABLE_CONTROL_DATA'&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      TABLE_CONTROL                        =  tc&lt;/P&gt;&lt;P&gt;      CALLBACK_PROGRAM                     =  pgm&lt;/P&gt;&lt;P&gt;     CALLBACK_TOP_OF_LIST                 =    'TABLE_TOP_OF_LIST'&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    CALLBACK_TOP_OF_PAGE                 =&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    CALLBACK_END_OF_PAGE                 =&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    CALLBACK_END_OF_LIST                 =&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;     OPTIMIZE_COLUMN_WIDTH                = 'X'&lt;/P&gt;&lt;P&gt;     GET_CURR_QUAN_FIELDS_FROM_DDIC       = 'X'&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    WINDOW_TITLE                         = 'PRINT TABLE'&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      PRINT_IMMEDIATELY                    = 'X'&lt;/P&gt;&lt;P&gt;    TABLES&lt;/P&gt;&lt;P&gt;      PRINT_DATA                           =  ITAB&lt;/P&gt;&lt;P&gt;   EXCEPTIONS&lt;/P&gt;&lt;P&gt;     COLUMN_INFORMATION_MISSING           = 1&lt;/P&gt;&lt;P&gt;     PRINTING_NOT_POSSIBLE                = 2&lt;/P&gt;&lt;P&gt;     OTHERS                               = 3&lt;/P&gt;&lt;P&gt;            .&lt;/P&gt;&lt;P&gt;  IF SY-SUBRC &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt; MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO&lt;/P&gt;&lt;P&gt;         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Venkat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 15:02:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009562#M711185</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T15:02:06Z</dc:date>
    </item>
    <item>
      <title>Re: Printing data from table control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009563#M711186</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Have you created a form with name 'TABLE_TOP_OF_LIST' ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM TABLE_TOP_OF_LIST.&lt;/P&gt;&lt;P&gt;write: /(10) 'I am title'.&lt;/P&gt;&lt;P&gt;endform.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh Patel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 15:12:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009563#M711186</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2007-11-05T15:12:16Z</dc:date>
    </item>
    <item>
      <title>Re: Printing data from table control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009564#M711187</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;But nimesh there is a blank header line being printed at the top how to prevent that from printing. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Venkat.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 15:19:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009564#M711187</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T15:19:48Z</dc:date>
    </item>
    <item>
      <title>Re: Printing data from table control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009565#M711188</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry, yes i did create a subroutine with that name but i was thinking instead we could print that thing in the blank header itself. Actually what is happening now is,&lt;/P&gt;&lt;P&gt;I have all the data lines which has data in it, but along with that i also have a blank header line with that, this line is additional line with all spaces in them. I was thinking that we could some how print the headers in them instead of using subroutine which would pirnt above the table .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 15:25:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009565#M711188</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T15:25:52Z</dc:date>
    </item>
    <item>
      <title>Re: Printing data from table control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009566#M711189</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry, I don't have much idea about that. &lt;SPAN __jive_emoticon_name="sad"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh Patel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 15:30:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009566#M711189</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2007-11-05T15:30:07Z</dc:date>
    </item>
    <item>
      <title>Re: Printing data from table control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009567#M711190</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I copied and changed the same function module to suit to my needs and that helped solve my problem&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Nov 2007 14:45:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009567#M711190</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-06T14:45:12Z</dc:date>
    </item>
    <item>
      <title>Re: Printing data from table control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009568#M711191</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi everybody,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I know that the problem has been solved a couple years ago by copying and adjusting FM, but for anybody that googles out this thread there's an easier workaround.&lt;/P&gt;&lt;P&gt;The thing with blank header is that most probably table control displays data from internal table declared with TYPES in the program (at least that was my case). FM FITRV_PRINT_TABLE_CONTROL_DATA makes its own "FIELDCATALOG_MERGE" (so do speak) and tries to find display characteristics in DDIC, but it can't find any.&lt;/P&gt;&lt;P&gt;There are 2 fixes:&lt;/P&gt;&lt;P&gt;- base your table control on DDIC&lt;/P&gt;&lt;P&gt;- if you can't for some reason, before FM call replace your program structure name with DDIC structure name. It's kept in tc parameter (table control). It has a field COLS, which is a table of columns from your table control. Each line in COLS has a field SCREEN, and there there's field NAME, where "[STRUCT]-[FIELD]" sits. Just replace STRUCT with your DDIC structure name and you're good to go.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Sep 2015 12:31:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/printing-data-from-table-control/m-p/3009568#M711191</guid>
      <dc:creator>sobon_lukasz</dc:creator>
      <dc:date>2015-09-18T12:31:50Z</dc:date>
    </item>
  </channel>
</rss>

