Downloading as .txt including header,itab footer with specific path

i have a specifix path like C://asd , an internal table itab, and a footer and header. I tried to use GUI_DOWNLOAD but, i can only send an internal table to this function.
I need to download these things .txt like this format
    The account 21324.2342                           (Header)
    123 1231 123 1234 123 1234 123 1234    (itab[1])
    321 4321 321 4321 321 4321 321 4321    (itab[2])
    123 1231 123 1234 123 1234 123 1234    (itab[3])
    321 4321 321 4321 321 4321 321 4321    (itab[4])
    123 1231 123 1234 123 1234 123 1234    (itab[5])
    321 4321 321 4321 321 4321 321 4321    (itab[6])
    Sum is 123412                                           (Footer)

Hi ,
In function module GUI_DOWNLOAD there is a parameter called as append.
Cal this FM for 3 times,
1: For Header with append not used.
2: For Internal table with append as 'X'.
3: for Footer with append as 'X'.
In all the call keep the file name same .
  CALL METHOD cl_gui_frontend_services=>gui_download
    EXPORTING
      filename                  = lv_filename
      filetype                  = 'ASC'
    CHANGING
      data_tab                  = gt_header
    EXCEPTIONS
      OTHERS                    = 1.
  CALL METHOD cl_gui_frontend_services=>gui_download
    EXPORTING
      filename = lv_filename
      filetype = 'ASC'
      append   = c_x
    CHANGING
      data_tab = p_gt_line
    EXCEPTIONS
      OTHERS   = 1.
  CALL METHOD cl_gui_frontend_services=>gui_download
    EXPORTING
      filename = lv_filename
      filetype = 'ASC'
      append   = c_x
    CHANGING
      data_tab = gt_control
    EXCEPTIONS
      OTHERS   = 1.
Regards,
Ganesh.
Edited by: Ganesh Lathi on Dec 21, 2011 8:08 AM

Similar Messages

  • After applying full scroll bar to the page including header and footer, Text editor ribbon actions cause page to automatically scroll down (while applying formatting)

    After applying full scroll bar to the page including header and footer, I have provided content to
    the page more than 100 lines and try to format the text from ribbon actions(format text area). On mouse over of font or fore color, the control jumps to the highlighted content area and not able to select the color. The page scrolls down and not able to click
    on any action.
    Consider this scenario also.
    A content editor web part is added toward the bottom of the page.
    Text is added to this (direct in the web part, not via a 'content link')
    You highlight some text and go to the Markup Style dropdown...
    Everything is fine until you hover over the "Paragraph" markup style, and suddenly the page scrolls to the web part you are editing, and you didn't have a chance
    to click and apply the "Paragraph" formatting
    I have tried testing this with text typed directly into the Content Editor, text pasted in from somewhere else, and text pasted in from somewhere else using "Paste as
    Plaintext" option in the ribbon.  In each scenario, I get the same results.
    Furthermore, I have also tested this in both IE8 and IE9 and get the same results.
    I can get it to occur most regularly with trying to apply the Paragraph "Markup Style" but
    I've also seen this happen with Font Size (any font size).  It's very frustrating since you aren't able to actually apply the formatting you need because the page jumps before you can click.  Has anyone experienced this before. Any feedback would
    help.

    Hi,
    According to your post, my understanding is that after applying full scroll bar to the page including header and footer, Text editor ribbon actions cause page to automatically scroll down (while applying formatting).
    I try to apply full scroll bar to the page including header and footer, the ribbon is missing after I scroll down to the web part. And I cannot apply the "Paragraph" markup style to the content.
    I recommend to use the SharePoint core styles to preserve the native functionality and GUI.
    By design in SharePoint, the ribbon is always at the top. When you select the content, you can apply the "Paragraph" markup style in the ribbon.
    Thanks,
    Linda Li
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Linda Li
    TechNet Community Support

  • How to create schema for Header and Footer with pipe delimiter file BPEL11g

    Hi all,
    I have issule creating Schema for Header and Footer with body file .The file format is Pipe delimiter.The following format below like is...
    Softeware Components:File Adapter(Read) 11g,
    1|1211|000|577|5444
    1|0000|57|6988|4554|sfdgh|5448|3333|ituu|44445|55546|544|788|7788
    1|0000|57|6988|4554|sfdgh|5448|3333|ituu|44445|55546|544|788|7788
    1|0000|57|6988|4554|sfdgh|5448|3333|ituu|44445|55546|544|788|7788
    1|0000|57|6988|4554|sfdgh|5448|3333|ituu|44445|55546|544|788|7788
    1|0000|57|6988|4554|sfdgh|5448|3333|ituu|44445|55546|544|788|7788
    1|0000|57|6988|4554|sfdgh|5448|3333|ituu|44445|55546|544|788|7788
    1|4544|000|yted
    I hope get the sollution for this from this Forum..Please help me out..Thankyou.

    You mean how many rows or columns..?
    If coloumns means 5 and rows only one(1).

  • How to create Schema Header and footer with Pipe delimiter file..?

    Hi all,
    I have issue with creating Schema Header and footer with body file ..The file format is Pipe delimiter.. The follwing file below like is...
    Adapters:File Adapter(Read)-11g.
    1|000|2025|SDFG|54787
    1|2055|244|9566|000|000|044|2577|361147|45554|wweqw|52555|564|000|647|464
    1|2027|344|4566|000|000|044|8577|361147|45554|wweqw|82555|564|000|647|844
    1|2024|444|6566|000|000|044|9577|361147|45554|wweqw|12555|564|000|647|544
    1|2023|544|8566|000|000|044|5577|361147|45554|wweqw|52555|564|000|647|442
    1|2022|644|3566|000|000|044|7577|361147|45554|wweqw|02555|564|000|647|448
    1|0000|546|25544|454
    If you have sollution for this, please help me out..Thank you.

    You mean how many rows or columns..?
    If coloumns means 5 and rows only one(1).

  • Problem in Consistent Header and Footer with Sub Templates in BI publisher

    Hi All,
    I have recently started working with OBI and used Sub templates for getting Consistent Header and Footer in all of our reports. I did this in the following way
    1. Created one template called HeaderFooter.rtf with Header and footer templates.
    2. placed the file in web server and called in the main Template with
    <?import: http://myserver.com:9704/xmlpserver/HeaderFooter.rtf?> I mean as static URL and it is working fine.
    3. Now as a part of generalizing the server i have added HTTPSERVER property in xdo.cfg file which is located in
    %BI_REPOSITORY%/Admin/Configuration.
    4. I have checked this property by placing <?xdoxslt:getXDOProperties($_XDOCTX)? in my rtf file and HTTPSERVER property is showing same as that of static.
    5. Now when i place <?import:http://{$HTTPSERVER}/HeaderFooter.rtf?> in my rtf it is ending with an error.
    so can anyone please help me out in this regard?

    Hi User XY,
    you might want to ask this in the [url http://forums.oracle.com/forums/forum.jspa?forumID=245]BI Publisher Forum
    brgds,
    Peter
    Blog: http://www.oracle-and-apex.com
    ApexLib: http://apexlib.oracleapex.info
    BuilderPlugin: http://builderplugin.oracleapex.info
    Work: http://www.click-click.at

  • Write a file with specific path

    hi all,
    i found some sample code to write into a file, like using new FileOutputStream or new FileWriter.
    the problem is that you only specify the file name. i'd like to specify the path where the file will be. is it possible ? which class should i use ?
    regards

    Hi,
    File f = new File("C:\\Programs\\MyProgs\\Test.txt");
    that should do.
    Phil

  • Header / footer with RTF template

    Hi all,
    My problems are below:
    - I want to create RTF template for a BI Publisher report. On that template, I would like to have a group of data that is printed only on the last page of the report (as a summary document end). For example, if, when I print my report, the used datamodel in my template selects datas to be printed on 5 pages, I want that some datas appear only on the fifth page and if the datamodel selects datas to be printed on 10 pages, I want that some datas appears only on the tenth page etc...
    How to do that ?
    -Also, how to use header and footer otherwise that hard code tags in header and footer ? Also, finally do you have some tutorials or samples to use complex header and footer with RTF template ?
    Thank you.
    Michaël.
    CGSI.

    i have a problem with header and footer too can you please help me out..
    <?call:Header?>
    group ROW by saw0_
    <?template: Header?>
    Account ID: saw0_
    <?end template?>
    Total saw17_
    page breakend ROW by saw0_
    i have a column saw_0 which i want to show as header in each page. and for each new saw_o i want to show it in next page.
    but currently in the header it shows the last row fetched by saw_o.
    while saw_0 has more than 1 value.

  • Header and footer in PDF files generated from Business Publisher

    Hi All,
    Is there any out of box feature to include Header and Footer of our choice in the Pdf file of Process Model generated from Business Publisher (from Print function in the publisher explorer)
    Thank you all in advance.
    regards,

    Hi Raja,
    Does this mean that you have been sucessful in generating the PDF from the BPublisher?
    If yes, could you please share how you achived this. Platform .. version ect. you have.
    I am trying to create the PDF , but my IE popup just ... well ... just disappears..
    thanks
    regards
    Sanjiv

  • I have just updated to Pages 5.1 and now the templares which I have saved do not displat the header and footer which they were saved with in the previous version.  How can I have the header and footer included when I open a template?

    I have just updated to Pages 5.1 and now the templares which I have saved do not displat the header and footer which they were saved with in the previous version.  How can I have the header and footer included when I open a template?

    That is becuase Pages 5.1 has numerous unnounced surprises for the unwary user.  Among the surprises:
    - it strips out images from headers and footers without warning
    - it strips out bookmarks without wanring (yes, all those bookamrks you laboriously put into a document: poof! Gone.)
    - it strips out alternating left/right margins, without warning.
    There are many more suprises, as you'll see from glancing through these discussions. They fall into two main categories: things that are present in version 4.3 but that are missing in 5.1, things like
    -mail merge
    -meaningful Applescript/Services support
    -non-contiguous text selection
    -ability to set defaul zoom
    -ability to see comments while editing
    -ability to print comments
    -ability to read RTF files
    -ability to drag in hyperlinked ted from a browser
    These about about 90 other features are gone.
    Then there are the bugs.  Hyperlinks do not reliably export to a PDF file any longer. There have been multiple problems with printing report. Some fonts place stray characters in the headers.  Many reports of the program crashing, courrupting files, etc.
    Fortunately for you, the previous version of Pages is still on your system.  Export any documents you may have created or edited with Pages 5.1 (another great surprise: files created with version 5.1 cannot be read by any previous version of Pages: not just 4.3 but even 5.01!).  Then trash 5.1 and use 4.3 until (unless?) it is stable and has a reasonably robust feature set.

  • How to download the output of a report along with column header

    Hi,
    Could someone please tell me on how to download the output of a report along with column header to .txt format. A download option needs to be given to the user using physical and logical file names .The report basically contains header details and item details and requirement is to download the same format into an .txt format.

    Hello,
    Try this FM:
    Data: being of itab occurs 0,
    matnr like mara-matnr,
    maktx like makt-maktx,
    end of itab.
    data:begin of fld_tab occurs 0,
    fld_name(20),
    end of fld_tab.
    fld_tab = 'Material'.
    append fld_tab.
    fld_tab = 'Material Desc'.
    append fld_tab.
    CALL FUNCTION 'WS_DOWNLOAD'
       EXPORTING
            BIN_FILESIZE            = ' '
            CODEPAGE                = ' '
             FILENAME                = 'C:\1.txt '
             FILETYPE                = 'DAT'
            MODE                    = ' '
            WK1_N_FORMAT            = ' '
            WK1_N_SIZE              = ' '
            WK1_T_FORMAT            = ' '
            WK1_T_SIZE              = ' '
            COL_SELECT              = ' '
            COL_SELECTMASK          = ' '
            NO_AUTH_CHECK           = ' '
       IMPORTING
            FILELENGTH              =
         TABLES
              DATA_TAB                = itab
              FIELDNAMES              = fld_tab
       EXCEPTIONS
            FILE_OPEN_ERROR         = 1
            FILE_WRITE_ERROR        = 2
            INVALID_FILESIZE        = 3
            INVALID_TYPE            = 4
            NO_BATCH                = 5
            UNKNOWN_ERROR           = 6
            INVALID_TABLE_WIDTH     = 7
            GUI_REFUSE_FILETRANSFER = 8
            CUSTOMER_ERROR          = 9
            OTHERS                  = 10
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    Regards,
    Naimesh

  • Csv-export with dynamic filename or include a report footer?

    Hi All,
    I have a question regarding the exported csv file contains a variable value as part of the file name.
    I read the following thread and example from Denes here:
    http://htmldb.oracle.com/pls/otn/f?p=31517:39:2021865942697087
    How to generate Excel file name
    I created a test page per instruction and I could successfully duplicate the effort and verified the csv file contains the variable value if I click on 'export to CSV' from the link.
    However, the application I am working on is slightly different. Basically in page 1, there is a 'download' button which branches to the page 2. And in page 2, in Layout and Pagination section, the value for the Report Template is set to Export CSV. In REport Export session, I set enable CSV output to Yes and file name is: &P20_REPORT_DATE..csv. Of course, I also have a hidden item &P20_REPORT_DATE whose value gets set in page process before header. Note: in this case, the user never really see the search results on screen when they click on the 'download' button which is different from the above example.
    When I run the application, the file name simply doesn't show up correctly, instead it is &P20_REPORT_DATE.csv. It appears that the value of the P20_REPORT_DATE is never set.
    Also, is there any way I could include a report header or footer to indicate when the report is generated?
    Your help is greatly appreciated.
    Thanks,

    Hi all,
    I'm using Application Express 3.1.1.00.09.
    What I want to do is include the current date in the report filename. I created an item on Page 0 called P0_CURR_DATE, which is the value of "select current_date from dual". So, the filename I attempted to create is Vendor_&P0_CURR_DATE._report (notice the & and the . are included).
    When I click the report csv report link, the popup window shows file name as Vendor__report.csv (that's two underscore characters with no characters in-between).
    I think that I have figured out my problem. I originally created the item on Page 0, as "Display as Text (does not save state)". So, after I change the item to "Display as Text (saves state)", the csv report filename becomes Vendor_28-JUL-08_report.csv .
    I guess that's the pitfalls of being a newbie!
    Thanks to all who offered help and suggestions.
    Bryan
    Message was edited by:
    BryanG

  • Show rtf file with header and footer  in Editor

    hi
    I want to open an rtf file which contains header and footer.The file i got is opened but the header and footer are not there.these all done with Editor.Please kindly go thru this and give me a solution.

    Hello,
    when you do yourEditorPane.getStyledDocument().dump(System.out), if you don't see and footer or header, you must write your own RTFEditorKit, but you must know how an RTF file is coded (but i don't know this coding...)

  • How to display 2 layouts with 2 different Header and Footer in a template.

    Hi,
    I am using XML Publisher 5.5. I have created one template which is having two layouts. I am using <?Start: Body?> and <?end body?> for displaying Headers and footers. Now my problem is, I need to display first layout with it's associated Header and footer and then second layout with other header and footer. But the two layouts should come in single template file. How is it possible?. Is there any work around? Please help me as this is the urgent requirement to my client.
    Thanks.
    Siva.

    No problem. Select Insert -> Break from the menu bar. Then select a "Section Break" - Next page.
    Header 1
    <?start:body?>
    Page 1
    <?end: body?>
    Footer 1
    ==================Section Break (Next Page)=================
    Header 2
    <?start:body?>
    Page 2
    <?end: body?>
    Footer 2
    Worked like a charm.
    Klaus

  • Header and footer on a csv download

    Hi
    Is there an easy way to add an extra header and footer to a csv download ?
    What the user wants is a csv of the format
    New heading --- the additional heading
    col name, col name ..... -- the existing column names
    value, value ..... -- the existing values
    New footer -- some new text footer
    I have tried break formatting but have had no success. The csv produces perfectly but I can't get the additional lines added !
    Ta
    Bob

    No unfortunately I have not found the time to do a blog yet.
    Create a blank page and create an AFTER HEADER pl/sql process.
    Then add code like the following, changing query as needed
    declare
       cursor result_cur is
          select empno, ename, job
            from emp;
    begin
       htp.init; -- Wipe out the buffer
       owa_util.mime_header ('application/excel',false);
       htp.p('Content-Disposition: attachment; filename="FormResults.csv"');
       owa_util.http_header_close;
       -- write your header
       htp.p('This is my header');
       htp.p(' ');
       -- write out the column names
       htp.print ( 'Emp Num, Employee Name, Job' );
       --write out each row
       for it in result_cur loop
          htp.print ( '"'||it.empno||'","'||it.ename||'","'||it.job||'"' );
       end loop;
       -- write out footer
       htp.p(' ');
       htp.p('This is my footer');
       -- Send an error code so that the
       -- rest of the HTML does not render
       htmldb__application.g_unrecoverable_error := true;
    end;you can call this by making it the redirect target of a button or by adding something like the following in the footer section of your report region assuming the page you created the above process on was page 9
    <a href="f?p=APP_ID.:9:&SESSION.">Click here to download CSV</a>sorry the code above shows a # and does not show the f p syntax url which should be f followed by a ?p=&AMP;APP_ID.:9&AMP;:SESSION.
    Edited by: Larry Linnemeyer on May 20, 2009 8:08 AM

  • Header and Footer for PDF with images using itext.jar

    HeaderFooter class was available in itext.jar ,I tried using this class with PDFtemplate and Phrase i am trying to put the image on the header and footer ,however the image comes perfectly for the first page ,its not applicable for the second or continuous page, is it possible to have the images in header and footer?
    Regards,
    Venkateswaran

    Questions about third-party APIs should be asked in the forum/newsgroup specific to that API. These forums are for questions relating to the API as provided by Sun.
    Go find an iText forum.

Maybe you are looking for