sri sri

sri sri

  • NA
  • 11
  • 0

How to avoid the alert when an XML File is being modified

Apr 28 2008 7:22 AM

Hi,

I am saving the content from XMLFile1.xml to XMLFile2.xmll using the below code.

XmlDocument Xdoc=new XmlDocument( );

Xdoc.Load("XMLFile1.xml");

Xdoc.Save("XMLFile2.xml");

This code is working fine but after i finish running my code I am getting an alert saying

"This file is modified out of the source editor.Do you want to reload it". If I click "yes" only, the file is being saved otherwise not.

Is there any way to avoid that alert because, if the end users of this application will click "NO" or close the window, the application will throw an error.

Can anyone give me the code or any related link to this???

Thank You.