Need to Download the report from the workitem in the excelsheet format.

Hi,
Hi,
In my requirement i am displaying the PurchaseOrder details report to the Manager in the workitem he want to download the report (after execution of the workitem the manager approved the PO) in the form of EXCEL sheet.
Can anybody give the solution for this?
Early response is appriciable and rewardable?
Regards,
Chow

Hi Chow,
The workitem displaying the report must be part of some method of your BOR. This method must be either a ABAP program or function module depending on your requirement. In the same function module or ABAP program, you can have the code for downloading the data in excel.
Kindly find the following code for doing so. Here the file will be created on the desktop of your manager and the data will be downloaded into this excel as the program/function module gets executed in workitem. Here pass the output internal table to DATA_TAB.
CALL METHOD CL_GUI_FRONTEND_SERVICES=>GUI_DOWNLOAD
  EXPORTING
    FILENAME                  = 'C:Documents and Settings999999Desktopdemo.xls'
    FILETYPE                  =  'DBF'  
    WRITE_FIELD_SEPARATOR     = 'X'
*    HEADER                    = '00'
*    TRUNC_TRAILING_BLANKS     = SPACE
*    WRITE_LF                  = 'X'
  CHANGING
    DATA_TAB                  = lt_datatab.
Hope this helps you.
PS If the answer solves your query, plz close the thread by rewarding each reply.
Regards

Similar Messages

Maybe you are looking for

  • Difference between Logic Pro 9 and Logic Studio?

    I have garage band and I notice that the instruments available are extremely limited, so I am looking to upgrade solely for the idea of getting more instruments and more features. Does the app store Logic Pro 9 have the extensive amount of official i

  • VL10B err

    Hello all, In STO PO is created. But when del. is being created by VL10B, aftr entering PO no. & pressing F8, no line item is coming on the scr: u201CActivities Due for Shipping u201CPurchase orders, fast displayu201D. Why- can any body tell? Rgds.

  • Viewing result in a frame

    Iam writing a GUI that takes users information, I want to be able to let the users view the information they entered. I use getText() to fetch the input from textfield,but when the user clicks enter, instead of the traditional System.out.print("Resul

  • Forum Font Too Small

    Can someone please consider increasing the forum font from what looks like 8pt and make it more legible - I'm viewing on a 24 inch and even with glasses, the new layout is a strain on the eyes. Not all of us are under the age of 25 years. Thank you.

  • Photoshop Cs5, opengl, large files, performance issues.

    Hello I have fresh win7 64-bit install. Also I have fully upgraded system, new cool whql drivers and my old file form Cs4. Specs: Intel D5400xs board Dual quad xeons 8Gig ram Nvidia 9800GT 512 Card (Maybe it's not a quadro or other fancy sh*, but lik