We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Detecting a background file change

Hi,

Is there a way to get Essential Edit to "watch" the file it currently is editing and prompt the user to reload the file if some other process modifies it?

I have the Edit control set to allow shared files but I need to inform the user if that file is changed by another process and give them the chance to reload it.

Thank you,
Jon

1 Reply

SK Sarath Kumar G Syncfusion Team June 20, 2007 02:23 AM UTC

Hi Jon,

Thank you for your interest in Syncfusion products.

Yes it is possible to watch the file which is loaded to the editcontrol. This is achived by using "FileSystemWatcher", which watches the changes done to the loaded file. The changes

made to the file is then saved. I have created a sample to explain this. Please do the following to execute the application.

1) Open and execute the sample attached.
2) Make changes to the file loaded in the editor control.
3) Click the "Save" button.
4) "The file is changed", Message will be displayed - click ok.
6) Click Reload button to load the modified file in the other editor of the form.

Here is the sample for your reference.

http://websamples.syncfusion.com/samples/Edit/F-62572/main.htm

Hope so this meets your requirements. Please let me know for further help.

Regards,
Sarath

Loader.
Live Chat Icon For mobile
Up arrow icon