on 02-20-2014 1:51 PM
Hello,
I want to use a report programm in a web dynpro app. I already can use the report and save the file in my local, therefor i open a new html ui window in my web dynpro with the fallowing code:
**********************************************************************************************
concatenate 'https://' sy-sysid '.wdf.sap.corp' into lv_url.
concatenate lv_url '/sap/bc/gui/sap/its/webgui' into lv_url.
concatenate lv_url '?~transaction=ZDH_DOWNLOAD_OBJ' into lv_url. *ZDH_DOWNLOAD_OBJ is the report name
lo_api_component = wd_comp_controller->wd_get_api( ).
lo_window_manager = lo_api_component->get_window_manager( ).
condense lv_url no-gaps.
lo_window = lo_window_manager->create_external_window(
url = lv_url
modal = abap_true
).
lo_window->open( ).
************************************************************************************************
But when i test this it looks very unsightly! Do you know a function or something, within the user doesn't see a windows like the html ui working, but just recognize that the download/usage of the report was succesfull. I heard about SUBMIT can i use this for my problem and how can I use this?
Thanks for all answers and advice,
Daniel
Hi,
It will look like that as ITS will open SAP GUI in html. In your report how you are downloading pdf files..? Try to move the logic to build the pdf xstring to a FM/class method and call it in your Web Dynpro Application.
In your WDA application create an Interactive UI and bind the source to an attribute of type xstring and set the pdf xstring data to that attribute or pass the pdf xstring data to cl_wd_runtime_services=>attach_file_to_response method to download it.
Regards,
Kiran
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for your advice! I can now download the PDF via cl_wd_runtime_services=>attach_file_to_response ! Therefor I can select my download path in a popup, but I want to download the PDF to a path, which I enter in a TextInput-Field in my View before download. So I don't want a pop up with "save cancel open" just "File download completed! "! Maybe I can do it with the I_INPLACE export parameter with type boolean false? I know that I have to build a pop up window etc. for my pop up, so I just need the download process.
I hope you understand my problem. : )
Regards,
Daniel
Thanks for this! Do you know, how I can do multiple downloads via cl_wd_runtime_services=>attach_file_to_response , because when i want to download more than one file I have to save each file with a pop up dialog. I am using a LOOP (selcted documents in a alv list) in which the method is located. How can I give the method more than one xstring or do I have to put all the xstrings of the documents (selected in the list) in one xstring ?
Regards,
Daniel
Hi,
To download multiple files at the same time, you have to use AcfUpDownload. I don't this it is possible with cl_wd_runtme_services=>attach_file_to_response.
Alternately, instead of downloading the selected files in ALV, you can create a extra column with button/ FileDownload UI and in onAction of button you can download the corresponding file.
Regards,
Kiran
User | Count |
---|---|
83 | |
24 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.