priyanka_kothari
asked on
The process cannot access the file D:\abc.xml because it is being used by another process.
Hi
I am loading a input xml into XML Document (InputXML), processing the xml document and then saves the result in a temporary xml file. When I copy temporary xml file to input xml, it gives me error. I am using File.Copy().
I am loading a input xml into XML Document (InputXML), processing the xml document and then saves the result in a temporary xml file. When I copy temporary xml file to input xml, it gives me error. I am using File.Copy().
can you post some code?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Instead of loading xmlDocument from file, I first read file into XMLTextReader and then I am loading into XML Document
ASKER
My problem was solved after i added Thread.Sleep and loaded file from XMLTextReader