cancel
Showing results for 
Search instead for 
Did you mean: 

Report Program that reads Excel File does not work in Webdynpro

Former Member
0 Kudos

Hi,
I have a report program that will open the excel file and execute the macro in it. This is working upon running in SAP GUI. However, when running in Webdynpro this is not working. This program is being called via transaction code and configured in PFCG(role based). Can someone help me out how to perform the requirement. Is this even possible?

Accepted Solutions (0)

Answers (2)

Answers (2)

pokrakam
Active Contributor
0 Kudos

Raymond is exactly right. When you write "open the excel file and execute the macro in it", this can only be done via OLE, which requires a SAPGUI installation on Windows.

Since WebDynpro apps are independent of a SapGUI, and can be run on Linux, OSX, Android, or whatever, this won't be possible using standard functionality. The best you could do is launch Excel (possibly using a download link?) and let the user execute the macro. It will be a bit unpredictable what happens if the user is running different browsers on different platforms, so generally not recommended.

Former Member
0 Kudos

Yes Mike, I agree that this can only be done via OLE. I am thinking of a possible solution that instead of the report program I would rather create a Dynpro application and utilize the SAP Office integration. Do you think based on my requirement, could this be possible? I am planning to upload the excel file first in the MIME repository and perform the execution of macro. But is this a good approach for this requirement? I have read different forums on this and still didn't come up with a solid solution. I hope you can help me out on this. Thank you!

pokrakam
Active Contributor
0 Kudos

Yes, going via MIME repository is an option, this is the type of setup I had in mind with my earlier suggestion of launching Excel.

I haven't used it, but perhaps it may be possible to open Excel inline within the browser window. In plain HTML this is achieved with the Content-Disposition tag, not sure if there is such a thing in the WDA download link components (no time to check).

raymond_giuseppi
Active Contributor
0 Kudos

You report seems to use some GUI functions that are not available in a WebDynpro (some CL_GUI* classes?) adapt your report to use other methods when executed without GUI session.

Former Member
0 Kudos

Thanks Raymond! I agree with you. Still going to look for other solution. Also, it would be greate if you could share some suggestions what classes and methods can I use for this requirement?