So I am using the FileStream
inside XmlReader
using (XmlReader reader = XmlReader.Create(new FileStream(archivePath, FileMode.Open), readerSettings))
{
reader.close()
}
However, the file feed into the XmlReader
is still in the lock state after the using
scope, weird, I thought the XmlReader
is going to close the FileStream
for me, is it not?
Thanks for help.