How do I change properties on control panel with visual studio

26 views Asked by At

hello here is my question: I recently figured how to change my mac address through control panel but I want to make it into a button on visual studio. I have no idea how to change things on OTHER apps with visual studio. My only experience is ProcessStartinfo which only opens the app and doesn't do anything else. so i'm wondering if theres a way to code something into a button where when you press it, it goes to this specific part in control panel and changes a property. for example: when I click this button on my form, it goes to the control panel then network and sharing center and then goes to my internet connection into properties then changes my network address (mac address). because i don't want to manually do it everytime, I have an idea on how to do it but when i searched it up it was just all tools to open specific parts in control panel and no info i needed which is actually CHANGING the properties in control panel. ok this might not be understandable but I hope you know what i'm saying. this is what i have right now

private void Button1_Click(object sender, EventArgs e)
        {
            ProcessStartInfo ps = new ProcessStartInfo();
            ps.FileName = "Control Panel.lnk";
           
            Process.Start(ps);
        }

I hope someone can help me with this

0

There are 0 answers