Any .NET API available to toggle the color filter windows settings?

Jone Selas 81 Reputation points
2022-05-24T15:13:18.783+00:00

I need to turn on /off my windows Color filter setting using .Net APIs.

205173-capture.png

Developer technologies C#
{count} votes

Accepted answer
  1. Castorix31 90,681 Reputation points
    2022-05-25T09:14:26.247+00:00

    It is done with Registry + atbroker to apply the change

    Test in C++ :

    int nActive = 1;
    int nRet = SHSetValue(HKEY_CURRENT_USER, L"Software\\Microsoft\\ColorFiltering", L"Active", REG_DWORD, &nActive, sizeof(nActive));
    ShellExecute(NULL, NULL, L"C:\\WINDOWS\\system32\\atbroker.exe", L"/colorfiltershortcut /resettransferkeys", NULL, SW_SHOWNORMAL);
    

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.