Doesn't this premise "On Windows" == "running on .NET" ? This actually has to work fine with "Mono runtime on Windows", so it rather wants different approaches to detect .NET runtime.