Activity Excel Scope does not end

excel
activities

#1

When Excel scope activity is used inside loop it does not end so that next loop it fails. any idea?

Alinos38


#2

Hello @Alain_Voorspoels,

Have you tried closing the workbook on each iteration? You can get the workbook from the output parameter Workbook of ExcelApplicationScope activity

Regards,
Susana


The process cannot access the file 'PATH' because it is being used by another process
#3

Hello,

Thanks. I thought about this solution but it is not the normal behavior because help of this activity says “When this Activity ends, the Workbook and Excel application are closed”.For me, it’s a bug!

Alinos38


#4

why not use loop inside excel scope?


#5

Again this workaround does not fix the bug!


#6

or you must change help for this activity to be in phase with the code :slight_smile:


#7

i don t really understand the problem here.
you have a loop (lets say for each item in an array)
and inside this loop you have an excel scope activity that opens an excel file
in do (for the excel scope) you write the item`s name in a cell
for each loop/item you ll open the excel file, do the write cell and close the workbook
then again and again…
the loop will continue until all the items in the array are consumed, then the workflow stops.


#8

It also says the following:


#9

So, this is a sheet :frowning_face:
Whatever, the code of this activity is not in phase with functionality == BUGG
Alinos


#10

For each loop, I use Excel Scope to use Write activity in order to write data in it.