Skip to main content
Answer

Why the Excel file can not be open using \*xlsm

  • December 8, 2022
  • 5 replies
  • 603 views

Forum|alt.badge.img+3

Recently AA cannot open Excel file using command.

Excel Open Spreadsheet E:\Data\02_Master\YEA_ENG_05\5K00\202211\*.xlsx

But this is working before.

Is the * wildcard is not working for this case?

Anyone has similar experence?

 

Best answer by Padmakumar

Mark this as best if it worked out for you so that other community members can easily access this thread for similar issues.

5 replies

Padmakumar
Premier Pathfinder | Tier 7
Forum|alt.badge.img+15
  • Premier Pathfinder | Tier 7
  • December 8, 2022

@MingshanX101307 ,

As I can see that, you are taking the Excel files from a local folder here. So, the best thing you can do here is that loop inside this folder and during each iteration, BOT will take each file and do the necessary actions according to the logic provided and go to the next one during next iteration.

 

 


Forum|alt.badge.img+3
  • Author
  • Cadet | Tier 2
  • December 8, 2022

yes, I try to start a loop in the folder, using if file extension = xlsm , then open the file name it works.


Padmakumar
Premier Pathfinder | Tier 7
Forum|alt.badge.img+15
  • Premier Pathfinder | Tier 7
  • Answer
  • December 8, 2022

Mark this as best if it worked out for you so that other community members can easily access this thread for similar issues.


Forum|alt.badge.img
  • Cadet | Tier 2
  • December 8, 2022

I have been successfully opening Excel files with wildcards, however, if there are five files in the same folder, all having the extension .xlsx, then when we choose to open a file with the *.xlsx extension, one file will be opened which appears first in alphabetical order.The Package i have used is 6.104

 

 


Padmakumar
Premier Pathfinder | Tier 7
Forum|alt.badge.img+15
  • Premier Pathfinder | Tier 7
  • December 8, 2022

@Shalord ,

 

I don’t think using wild card here will be a good option. Because if you put wild mask, BOT will only consider the file extension and whichever file comes first with .xlsx extension, it will pick that. So basically, it will keep taking the same file again and again.

 

Whereas looping inside the folder will iterate through all files and there will be no situation like above mentioned.