'File Change Trigger' activity not working with '.xlsx' file

Hi There,

Using ‘File Trigger Activity’ to trigger something whenever there is a change in the excel file (.xlsx). ‘Change Type’ is set to ‘Changed’ and ‘NotifyFilters’ is set to ‘Last Write’.

Tested it with text file(.txt) and it looks working fine there. However ‘Event Handler’ doesn’t execute when the file is an excel file. Isn’t this activity supposed to work with all types of files?

Thanks,
Rammohan B.

Hi Rammohan,

I tried creating small workflow and it is working for me, however when I update xlsx file, it is showing message box for 5-6 times. I am not sure why it is happening. If this workflow is not working in your uipath studio, I would suggest you to update excel and dependent packages. FileChangeTrigger.xaml (5.7 KB)
Test.xlsx (7.7 KB)

attached workflow and sample file

Thanks for the reply,

That happens with me for the text file, but message box appears twice instead of once.Also, I do have the updated package of ‘UiPath.Core.Activities’.

Thanks,
Rammohan B.

Can you please share your workflow and test file? I will test in my system to understand behavior

Its exactly the same as yours. I am just using a ‘File Trigger Activity’ with a message box inside the ‘Event Handler’.

Thanks,
Rammohan B.

Do you know why message box trigger multiple times ?

Hi @Rammohan91

How did you solve this issue?

Looking forward to your reply.

@Jolin Unfortunately No. I stopped trying that.

Thanks,
Rammohan B.

Has this issue been resolved?
I’m not able to get this working in the 2019.7.0 CE version of UiPath.

I’ve tried working with this every possible way. This feature simply does not work.

Apologies if this seems like a rant. I’m seriously evaluating the product for a team that deals with large scale Excel file processing. File detection mechanisms are a key and ubiquitous functions of integration software in this day and age.

I’m shocked that such basic features are not working in UiPath!

:open_mouth: :open_mouth: :open_mouth:

I’m going to have a real hard time selling this to my team in a review meeting next week.
:weary:

As a workaround, I’m using the Path Exists alternative. This means that I have to rename or move the file after it’s processed to make this activity work.

Not good!

Thanks for the feedback. We have reproduced the problem internally and have determined that it’s something specific to office file (Word, Excel, etc.). We are investigating and hope to have a solution for 19.10. In the meantime, if you change The NotifyFilters to “Attributes” that will trigger the event whenever a change is saved to the file.

2 Likes

Thanks @justmarks!

Looking forward to the fix. :+1:

We just completed the investigation and this is caused by Office products renaming files during save operations. When an office file is opened, a new ~File.xlsx file is created and that’s the file that Office is editing. Then when a save occurs, the original file is renamed to SOMETHING.tmp and ~File.xlsx is renamed to File.xlsx.

The File Changed Trigger is generic as it works on file changes in the system and we don’t have plans to add customized support for Office. To work around this, there are two options:

  1. Instead of triggering on NotifyFilter=‘Filename’, trigger off of ‘Attributes’
  2. Trigger off of file renames

The second options is a better practice and I’ve included a sample workflow showing how it works

FileTriggerTest-Excel.zip (13.5 KB)

4 Likes

Hi. I have downloaded the file and it has missing activity after assign. could you please reupload this?

error
Hi. I have downloaded the file but not working application.
Could you please upload?

Hi @Ceyhun_ASLAN,
Welcome!

Please click on the missing activity. On the right pane you will see the name of the activity.
All you have to do is add that package to your project and reopen the workflow to recover that activity.

Thanks

we are getting activities missing error in project panel also not showing any error please check onec

Hi @kalyanDev

Could you open the Package Manager and check if the UiPath.System.Activities are properly installed?

I think it is this activity, which requires this package:
image

1 Like

Does anyone solve this problem? I am facing the same issue.
When writing something on the excel file and save it, the run was just stuck and doing nothing.

hi @justmarks any update on this ? am still facing the same issue… trigger is not working for excel change / rename filter