How do I modify variables from a different class that belongs to the same C# file?

I’m making a small database that’s used to save Dropdown values (integers) in a XML database… currently it’s set up like this:

public class XMLManager : MonoBehaviour {
//other code before the variable below
public VideoSettings vSettingsDB;

        //save function
        public void SaveItems()
            //Configure save
            itemEntry.configSettings(); //This is what I basically am trying to aim for, but with no luck
            //open a new xml file
            XmlSerializer serializer = new XmlSerializer(typeof(VideoSettings));
            FileStream stream = new FileStream(Application.persistentDataPath, FileMode.Create);
            serializer.Serialize(stream, vSettingsDB);
        //load function (not done yet)
    public class itemEntry
        public int resolutionValue, shadowValue, lightValue, textureValue;
        public bool vSyncValue;
        UserInterfaceScript UI;
        public void configSettings()
            UI = GameObject.Find("GUI").GetComponent<UserInterfaceScript>();
            resolutionValue = UI.resolutionSetting.value;
            shadowValue = UI.shadowQuality.value;
            lightValue = UI.lightMode.value;
            textureValue = UI.textureQuality.value;
            vSyncValue = UI.VSync.isOn;
    public class VideoSettings
        public List<itemEntry> list = new List<itemEntry>();

I need some help as I can’t find anything related to modifying variables of another class in the same file :confused:

I found a solution to my issue using this plugin: Save Data | Tools | Unity Asset Store
It’s compatible with Unity 5.6 and it’s extremely easy to use