System.IO FileNotFound exception while loading XML file - Blazor

Job ID: 36204592

Budget: $10 – $30 USD

Need to read xml file by setting proper filepath - in both part1 and part2

1) FileA(cs file) and FileB(xml file) are in the same folder. Loading FileB from FileA. I get System.IO FileNotFoundException or DirectoryNotFoundException, depending on the filepath I try.

Pls read the details in the below stackoverflow link - to know what all I have tried:
https://stackoverflow.com/questions/75744733/system-io-filenotfound-exception-while-loading-xml-file

2) Even below returns null, need to read the xml file by setting proper path.
const string resourceName = "ProjectName.Client.SubFolder.abc.xml";
using var stream = assembly.GetManifestResourceStream(resourceName);

If you have tried loading xml file in blazor application before and good at c#, I would appreciate your help. Thank you.

Budget: $10 (fixed)
Related categories: XML C# Programming Blazor