How to use Excel activities on ".XLS" which throws "Format mismatch error while opening"

excel

#1

How to use Excel activities on “.XLS” which throws “Format mismatch error while opening”.

When we press OK, Excel automatically converts its format. But how to achieve same using Excel Activities


#2

What’s is your requirement?

Do you have to open the physicial file? then you can check for “on element appear” or “element exists” to click OK to continue on Format Mistmatch alert.

Or

you can load that file into a Datatable using Readrange activity? What’s the result if you do this?

You can always build a datatable whose columns maps the excel sheet data and then load the data.

Hope it helps.


#3

Hi,

I want to transform Excel to into another Excel. I wanted to do this using Excel activities only.

PFA for more info
UIpatherror.zip (20.7 KB)

Thanks and Regards,
Ajinkya Kadne


#4

Hi @AjinkyaCK

You gets this error when you will open an excel file via GUI automation. So you can use “Excel activities” with it.

  1. Use Excel Application Scope and pass it the path of that excel file with extension.
  2. Uncheck the “Visible” property of excel application scope activity so uipath will not open it visibly at the time of opening it.
  3. Use Read Range activity and assign it’s output to a Datatable variable.
  4. Assign the datatable to a new excel file using write range activity.You can use this with new excel applicaiton scope after the first one so if your new excel file does not exists it will generate a new file with that name.

Regards…!!
Aksh


#5

Hi Aksh,

Was following the same steps. I was getting issues in Step #3. In my earlier post I had attached Screenshot of same.

Thanks,
Ajinkya Kadne


#6

can you share that excel? and what office version you are using?