Skip to main content
Question

Is there any way to open Excel without using the path ?


Forum|alt.badge.img

I usually use Excel Advanced: Open without any problems, but this time I encountered an issue: When downloading an Excel table from the SAP system, SAP does not pop up the access window but instead downloads the file directly (without specifying a path). I have tried switching windows, but it fails every time because the window position changes.

4 replies

Marc Mueller
Pathfinder Advocate | Tier 6
Forum|alt.badge.img+15
  • Pathfinder Advocate | Tier 6
  • 275 replies
  • April 2, 2025

Hi ​@joann.wang,

where it is downloaded to?

 

Cheers

Marc


Aaron.Gleason
Automation Anywhere Team
Forum|alt.badge.img+10
  • Automation Anywhere Team
  • 564 replies
  • April 2, 2025

This could be one of those situations, like downloading a file using a browser, that it goes to a specific place with a semi-random name.

In those cases, the only thing you can do is to (1) ensure the folder is empty, (2) have SAP download the file to that folder, then (3) loop through all the files in that folder… there should only be one. Then you will have the filename of the Excel file and you can open it.


rbkadiyam
Premier Pathfinder | Tier 7
Forum|alt.badge.img+17
  • Premier Pathfinder | Tier 7
  • 589 replies
  • April 2, 2025

@joann.wang :

To ensure Excel opens automatically after downloading an Excel file from SAP, you may need to verify that the SAP add-in for Excel is enabled and that the SAP GUI scripting is enabled. 

Here's a more detailed breakdown:

1. Enable SAP Add-in for Microsoft Excel:

  • Open Excel: Launch Microsoft Excel.
  • Go to Add-ins: Navigate to File > Options > Add-ins.
  • Manage Disabled Add-ins: In the Manage section, select "Disabled Add-ins".
  • Click Go: Click the "Go..." button.
  • Check SAP Add-in: Locate and check the entry "SAP Add-in for Microsoft Excel".
  • Enable and OK: Click "Enable" and then "OK" to save the changes. 

                        

                                          (OR)

 

1. Using GUI_DOWNLOAD and CL_GUI_FRONTEND_SERVICES=>EXECUTE:

  • GUI_DOWNLOAD: This function module is used to download the Excel file from SAP.
  • CL_GUI_FRONTEND_SERVICES=>EXECUTE: This method is used to execute the downloaded file, in this case, opening it in Excel.
  • Parameters:
    • W_APPLICATION = 'EXCEL': Specifies that you want to open the file with Excel.
    • W_PARAMETER = W_PATH: Specifies the path to the downloaded Excel file.
    • Maximized = 'X': (Optional) Opens the Excel file in maximized mode.
    • Operation = 'OPEN': Specifies that you want to open the file.

Forum|alt.badge.img
  • Author
  • Cadet | Tier 2
  • 1 reply
  • April 7, 2025

Hi Marc Mueller , Aaron.Gleason and rbkadiyam

Thanks a lot for your advices 😆

Now: Can’t find the file in Download area and the Excel application icon turn red. 

→I use Find windows in windows(left click Excel icon) and successfully open the file. Or is there a better solution?  

 

 I need to use Excel advanced: Open and Excel advanced: Close but also without variable to open\close the excel file. Should I assign a variable for it?


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings