Unity Editor Scripting with XML

Hi there,

I am trying to read a XML File I have created but not sure how to, I am looking to read it inside my editor script rather then MonoBehaviour.

I am new to XML so i’m not even sure if I have written the script right.

Here is my XML::
csharp** **<?xml version="1.0" encoding="utf-8"?> <Hierarchy_IconsDB> <Settings> <Canvas_Settings> <Canvas_UI>TRUE</Canvas_UI> </Canvas_Settings> </Settings> </Hierarchy_IconsDB>** **
I have this XML file located in a resources folder.

Be very handy if someone can help me return the Canvas_UI data.

Thank you very much!

What’ve you tried to do?

C# has a built-in XML reader class, which you should be able to use.

1 Like

I understand that but I am still new to XML and was wondering if someone would be able to give me and example to read and write to that then I can continue off that.