Excel Exception Error

I’m using the Write Cell to put the following formula into cell J1 on sheet “hal”:

=COUNTIF(CP3:CP6000,">*00000000-0000-0000-0000-")

I get a “The range does not exist” error. Please help.

Please show the screenshot of read range.

I suspect you need to embed the quotations inside your formula string.

In the Write Cell, it should be like this:

"=COUNTIF(CP3:CP6000,"""">*00000000-0000-0000-0000-"""")"

image

Tried that, same error.

You are trying to write formula in CSV file. I’m not sure if CSV supports formula. Try the same in .xlsx file.

I got it to work by removing the “” around the last part in the formula. Works with “” straight in the csv, but not via uipath - weird.

Anyways, now have another issue. Receive error message as per screenshot below when trying to scrape value from a cell in the csv. It doesn’t seem to want to scrape it.

image

Here is screenshot of the sequence erroring out on "Attach Window ‘Hal Excel XLmain’

image

Hi Joe - Did you check with the selector, is it a validated selector.

The title in selector and the Excel title are different, plz use title=hal - Excel* in selector

2 Likes

I added the * as you indicated (see screenshot below) but I still get the same error.

image

I would highly recommend not using scraping on an Excel window. Read and Write Range or Cell steps would be much more reliable and proficient.

Going back to the Write Cell, it must not be inputting a valid formula. Normally I would double check this with a Message Box or Write Line to ensure the string being inputted is exactly what you want for the formula, and also verify that the formula works manually.

Even though I don’t recommend it, looking at your selector, I would suggest editing the title with a wildcard:

<wnd app='excel.exe' cls='XLMAIN' title='hal*' />

Sometimes the app name “- Excel” is not included on certain machines or even the extension will be there like hal.csv. So, wildcarding that part will be more consistent. EDIT: also the window needs to be open, if it isn’t already.

If you need someone to look at your first attempt using the Write Cell, maybe provide an example csv file and workflow that reproduces the issue, and a solution can be made.

Regards.

Add * in edit selector