A
AZBruno
Guest
Under VB in a Windows Form app, I am trying to read an XML file as follows:
Dim recDoc As XmlDocument = New XmlDocument
recDoc.Load("C:\Windows\System32\Recovery\ReAgent.xml")
What I have discovered is that it is actually reading a file of the same name under C:\Windows\WinSxS\wow64_microsoft_windows...
I tried using
Dim xmlString = My.Computer.FileSystem.ReadAllText("C:\Windows\System32\Recovery\ReAgent.xml")
but it too fails in the same way.
No difference whether I'm running the app as administrator or not. Since the two versions of the file are very different, is there any way to actually force it to read from where I am asking it to read. I have no trouble at all in Windows Explorer in being able to access the correct file.
Continue reading...
Dim recDoc As XmlDocument = New XmlDocument
recDoc.Load("C:\Windows\System32\Recovery\ReAgent.xml")
What I have discovered is that it is actually reading a file of the same name under C:\Windows\WinSxS\wow64_microsoft_windows...
I tried using
Dim xmlString = My.Computer.FileSystem.ReadAllText("C:\Windows\System32\Recovery\ReAgent.xml")
but it too fails in the same way.
No difference whether I'm running the app as administrator or not. Since the two versions of the file are very different, is there any way to actually force it to read from where I am asking it to read. I have no trouble at all in Windows Explorer in being able to access the correct file.
Continue reading...