151 references to Version
ComSvcConfig (2)
Tool.cs (2)
917
if ((Environment.OSVersion.
Version
.Major == 5) && (Environment.OSVersion.
Version
.Minor == 1))
mscorlib (10)
microsoft\win32\win32native.cs (1)
1501
if (Environment.OSVersion.
Version
>= ThreadErrorModeMinOsVersion)
system\diagnostics\eventing\eventsource.cs (2)
1520
var osVer = Environment.OSVersion.
Version
.Major * 10 + Environment.OSVersion.
Version
.Minor;
system\environment.cs (3)
1180
((OS.
Version
.Major == 6 && OS.
Version
.Minor >= 2) || (OS.
Version
.Major > 6)));
system\globalization\culturedata.cs (2)
649
Environment.OSVersion.
Version
< s_win7Version;
654
Environment.OSVersion.
Version
< new Version(6, 2); // Win7 is 6.1.Build.Revision so we have to check for anything less than 6.2
system\security\cryptography\cryptoconfig.cs (1)
62
if (Environment.OSVersion.
Version
.Major >= 6) {
system\security\cryptography\utils.cs (1)
527
Contract.Assert(Environment.OSVersion.
Version
.Major < 6, "CryptGetFIPSAlgorithmMode should be used on Vista+");
PresentationCore (7)
Core\CSharp\MS\Internal\FontCache\FamilyCollection.cs (3)
268
_usePrivateFontCollectionForLegacyArabicFonts = (osInfo.
Version
.Major < 6)
269
|| (osInfo.
Version
.Major == 6
271
osInfo.
Version
.Minor == 0);
Core\CSharp\System\Windows\Input\TextServicesContext.cs (1)
132
if (!appDomainShutdown || System.Environment.OSVersion.
Version
.Major >= 6)
Core\CSharp\System\Windows\Interop\OperatingSystemVersionCheck.cs (3)
54
(((os.
Version
.Major == major) && (os.
Version
.Minor >= minor)) || (os.
Version
.Major > major));
PresentationFramework (9)
src\Framework\Microsoft\Win32\FileDialog.cs (2)
1567
if (dereferenceLinks && System.Environment.OSVersion.
Version
.Major >= 5)
2100
get { return Environment.OSVersion.
Version
.Major >= 6; }
src\Framework\System\Windows\Controls\WebBrowser.cs (1)
1068
Version osver = Environment.OSVersion.
Version
;
src\Framework\System\Windows\Documents\TextFindEngine.cs (1)
488
if (System.Environment.OSVersion.
Version
.Major >= 6)
src\Framework\System\Windows\Documents\TextServicesHost.cs (1)
461
if (_thread == Thread.CurrentThread || System.Environment.OSVersion.
Version
.Major >= 6)
src\Framework\System\Windows\Interop\DocobjHost.cs (2)
434
if (os.
Version
.Major == 5 && os.
Version
.Minor == 1)
src\Framework\System\Windows\Standard\Utilities.cs (1)
29
private static readonly Version _osVersion = Environment.OSVersion.
Version
;
src\Framework\System\Windows\SystemParameters.cs (1)
1306
if (System.Environment.OSVersion.
Version
.Major >= 6)
System (17)
compmod\microsoft\win32\UnsafeNativeMethods.cs (1)
239
bool osSupportsPackagedProcesses = os.Platform == PlatformID.Win32NT && os.
Version
>= windows8Version;
net\System\Net\Internal.cs (3)
712
IsWin7orLater = (operatingSystem.
Version
>= new Version(6, 1));
714
IsWin7Sp1orLater = (operatingSystem.
Version
>= new Version(6, 1, 7601));
716
IsWin8orLater = (operatingSystem.
Version
>= new Version(6, 2));
services\monitoring\system\diagnosticts\EventLog.cs (1)
62
s_SkipRegPatch = (os.Platform == PlatformID.Win32NT) && (os.
Version
.Major > 5);
services\monitoring\system\diagnosticts\Process.cs (2)
795
(OperatingSystem.Platform != PlatformID.Win32NT || OperatingSystem.
Version
.Major < 5)) {
1337
if (OperatingSystem.Platform != PlatformID.Win32NT || OperatingSystem.
Version
.Major < 5)
services\monitoring\system\diagnosticts\ProcessManager.cs (5)
139
return Environment.OSVersion.
Version
.Major < 5 ||
140
(Environment.OSVersion.
Version
.Major == 5 && Environment.OSVersion.
Version
.Minor == 0);
151
if (!isRemoteMachine && IsNt && (Environment.OSVersion.
Version
.Major >= 5)) {
178
(Environment.OSVersion.
Version
.Major >= 5 )) {
services\monitoring\system\diagnosticts\SharedUtils.cs (1)
75
if (Environment.OSVersion.
Version
.Major >= 5)
sys\System\EnvironmentHelpers.cs (4)
20
} else if(Environment.OSVersion.
Version
.Major < 6 || (Environment.OSVersion.
Version
.Major == 6 && Environment.OSVersion.
Version
.Minor <= 1)) {
54
return os.Platform == PlatformID.Win32NT && os.
Version
.Major >= 6;
System.Core (8)
System\Diagnostics\Eventing\EventProvider.cs (4)
34
private static bool s_platformNotSupported = (Environment.OSVersion.
Version
.Major < 6);
35
private static bool s_preWin7 = (Environment.OSVersion.
Version
.Major < 6 || (Environment.OSVersion.
Version
.Major == 6 && Environment.OSVersion.
Version
.Minor < 1));
System\Diagnostics\Eventing\Reader\NativeWrapper.cs (1)
32
private static bool s_platformNotSupported = (Environment.OSVersion.
Version
.Major < 6);
System\Diagnostics\PerformanceData\CounterSet.cs (1)
28
private static readonly bool s_platformNotSupported = (Environment.OSVersion.
Version
.Major < 6);
System\Security\Cryptography\AesCryptoServiceProvider.cs (2)
43
if (Environment.OSVersion.
Version
.Major == 5 && Environment.OSVersion.
Version
.Minor == 1) {
System.Data (2)
fx\src\data\System\Data\Common\AdapterUtil.cs (1)
1880
static internal readonly bool IsPlatformNT5 = (ADP.IsWindowsNT && (Environment.OSVersion.
Version
.Major >= 5));
fx\src\data\System\Data\SQLTypes\UnsafeNativeMethods.cs (1)
142
if (Environment.OSVersion.
Version
>= ThreadErrorModeMinOsVersion)
System.Drawing (2)
commonui\System\Drawing\SystemFonts.cs (1)
312
Environment.OSVersion.
Version
.Major <= 4) {
commonui\System\Drawing\SystemIcons.cs (1)
174
if(Environment.OSVersion.
Version
.Major >= 6) {
System.IdentityModel (3)
System\IdentityModel\Claims\ClaimsHelper.cs (1)
27
if (Environment.OSVersion.
Version
.Major >= CryptoHelper.WindowsVistaMajorNumber)
System\IdentityModel\SecurityUtils.cs (1)
188
if (Environment.OSVersion.
Version
.Major >= WindowsVistaMajorNumber)
System\IdentityModel\Selectors\X509SecurityTokenAuthenticator.cs (1)
95
if (Environment.OSVersion.
Version
.Major >= SecurityUtils.WindowsVistaMajorNumber)
System.Management (6)
Instrumentation\WMICapabilities.cs (2)
162
if(os.Platform==PlatformID.Win32NT && os.
Version
>= new Version(5, 1))
182
if(os.Platform==PlatformID.Win32NT && os.
Version
>= new Version(5, 1))
InteropClasses\WMIInterop.cs (1)
2153
if(os.Platform==PlatformID.Win32NT && os.
Version
>= new Version(5, 0))
managementscope.cs (3)
1145
if( ((Environment.OSVersion.
Version
.Major == 5) && (Environment.OSVersion.
Version
.Minor >= 1)) || (Environment.OSVersion.
Version
.Major >= 6) )
System.Messaging (2)
System\Messaging\AccessControlList.cs (1)
46
if (Environment.OSVersion.
Version
.Major >= 5)
System\Messaging\MessageQueue.cs (1)
76
internal static readonly Version OSVersion = Environment.OSVersion.
Version
;
System.Runtime.Remoting (1)
channels\http\httpclientchannel.cs (1)
410
System.Environment.OSVersion.
Version
+
System.ServiceModel (22)
System\ServiceModel\Channels\Msmq.cs (1)
25
Version osVersion = System.Environment.OSVersion.
Version
;
System\ServiceModel\Channels\UnsafeNativeMethods.cs (1)
1166
bool osSupportsPackagedProcesses = os.Platform == PlatformID.Win32NT && os.
Version
>= windows8Version;
System\ServiceModel\ComIntegration\ComPlusInstanceProvider.cs (4)
162
if (Environment.OSVersion.
Version
.Major > 5)
164
else if (Environment.OSVersion.
Version
.Major == 5)
166
if (Environment.OSVersion.
Version
.Minor > 2)
168
else if (Environment.OSVersion.
Version
.Minor == 2)
System\ServiceModel\Dispatcher\SecurityValidationBehavior.cs (1)
386
Version osVersion = Environment.OSVersion.
Version
;
System\ServiceModel\OSEnvironmentHelper.cs (3)
16
currentServicePack = (byte)Environment.OSVersion.
Version
.MajorRevision;
18
int major = Environment.OSVersion.
Version
.Major;
19
int minor = Environment.OSVersion.
Version
.Minor;
System\ServiceModel\Security\SecurityUtils.cs (12)
316
return ((Environment.OSVersion.
Version
.Major >= SecurityUtils.XPMajorNumber && Environment.OSVersion.
Version
.Minor > SecurityUtils.XPMinorNumber) ||
317
Environment.OSVersion.
Version
.Major > SecurityUtils.XPMajorNumber);
323
return (Environment.OSVersion.
Version
.Major >= windows7Version.Major && Environment.OSVersion.
Version
.Minor >= windows7Version.Minor);
2307
if ((Environment.OSVersion.
Version
.Major > WindowsServerMajorNumber)
2308
|| (Environment.OSVersion.
Version
.Major == WindowsServerMajorNumber && Environment.OSVersion.
Version
.Minor > WindowsServerMinorNumber))
2313
if (Environment.OSVersion.
Version
.Major == XPMajorNumber && Environment.OSVersion.
Version
.Minor == XPMinorNumber)
2325
else if (Environment.OSVersion.
Version
.Major == WindowsServerMajorNumber && Environment.OSVersion.
Version
.Minor == WindowsServerMinorNumber)
System.ServiceModel.Internals (1)
System\Runtime\Diagnostics\EtwDiagnosticTrace.cs (1)
40
static bool isVistaOrGreater = Environment.OSVersion.
Version
.Major >= WindowsVistaMajorNumber;
System.Web (4)
Util\SmtpMail.cs (3)
295
Version osVersion = Environment.OSVersion.
Version
;
463
else if (Environment.OSVersion.
Version
.Major <= 4) {
490
else if (Environment.OSVersion.
Version
.Major <= 4) {
Util\Transactions.cs (1)
69
if (Environment.OSVersion.Platform != PlatformID.Win32NT || Environment.OSVersion.
Version
.Major <= 4)
System.Windows.Forms (19)
misc\DpiHelper.cs (1)
177
(Environment.OSVersion.
Version
.CompareTo(ConfigurationOptions.RS2Version) >= 0) &&
misc\GDI\WindowsFont.cs (2)
575
if (Environment.OSVersion.
Version
.Major == 5 && Environment.OSVersion.
Version
.Minor >= 1)
winforms\Managed\System\WinForms\Clipboard.cs (3)
335
Environment.OSVersion.
Version
.Major < 5)
426
Environment.OSVersion.
Version
.Major < 5)
549
Environment.OSVersion.
Version
.Major < 5)
winforms\Managed\System\WinForms\FileDialog.cs (2)
832
if (dereferenceLinks && System.Environment.OSVersion.
Version
.Major >= 5)
1012
Environment.OSVersion.
Version
.Major < 5) {
winforms\Managed\System\WinForms\InputLanguage.cs (1)
313
if (layoutDisplayName != null && Environment.OSVersion.
Version
.Major >= 5) {
winforms\Managed\System\WinForms\ListBox.cs (1)
805
Environment.OSVersion.
Version
.Major < 5) {
winforms\Managed\System\WinForms\OSFeature.cs (3)
70
&& Environment.OSVersion.
Version
.CompareTo(new Version(5, 0, 0, 0)) >= 0) {
98
onXp = Environment.OSVersion.
Version
.CompareTo(new Version(5, 1, 0, 0)) >= 0;
108
onWin2k = Environment.OSVersion.
Version
.CompareTo(new Version(5, 0, 0, 0)) >= 0;
winforms\Managed\System\WinForms\Printing\PrintDialog.cs (4)
249
Environment.OSVersion.
Version
.Major < 5)) {
359
Environment.OSVersion.
Version
.Major < 5)) {
441
if (Environment.OSVersion.
Version
.Major >= 6) {
539
if(Environment.OSVersion.
Version
.Major >= 6) {
winforms\Managed\System\WinForms\PropertyGridInternal\GridEntry.cs (1)
2220
if (Environment.OSVersion.
Version
.Major > 4) {
winforms\Managed\System\WinForms\UnsafeNativeMethods.cs (1)
259
(os.
Version
.CompareTo(VistaOSVersion) >= 0);
System.Xml (1)
parent\parent\parent\parent\InternalApis\NDP_Common\inc\Win8Helpers.cs (1)
70
if(os.Platform == PlatformID.Win32NT && os.
Version
>= new Version(6,2,0,0) && DoesWin32MethodExist(KERNEL32, "GetCurrentPackageId"))
UIAutomationClient (3)
MS\Internal\Automation\HwndProxyElementProvider.cs (1)
1759
if (Environment.OSVersion.
Version
.Major >= 6)
MS\Internal\Automation\Misc.cs (1)
559
&& System.Environment.OSVersion.
Version
.Major >= 6)
MS\Win32\UnsafeNativeMethods.cs (1)
190
if (System.Environment.OSVersion.
Version
.Major >= 6)
UIAutomationClientsideProviders (28)
MS\Internal\AutomationProxies\Accessible.cs (1)
173
if(Environment.OSVersion.
Version
.Major >= 6)
MS\Internal\AutomationProxies\CommonGetThemePartSize.cs (1)
23
if (Environment.OSVersion.
Version
.Major >= 5)
MS\Internal\AutomationProxies\CommonXSendMessage.cs (7)
634
if (Environment.OSVersion.
Version
.Major == 5)
646
if (Environment.OSVersion.
Version
.Major == 5)
658
if (Environment.OSVersion.
Version
.Major == 5)
1495
if (Environment.OSVersion.
Version
.Major > 5 || (Environment.OSVersion.
Version
.Major == 5 && Environment.OSVersion.
Version
.Minor == 1))
1517
else if (Environment.OSVersion.
Version
.Major == 5)
MS\Internal\AutomationProxies\Misc.cs (6)
302
bool result = (System.Environment.OSVersion.
Version
.Major >= 6) ? UnsafeNativeMethods.GetPhysicalCursorPos(ref pt)
1042
&& System.Environment.OSVersion.
Version
.Major >= 6)
1231
if (System.Environment.OSVersion.
Version
.Major >= 6)
1890
if (Environment.OSVersion.
Version
.Major >= 6 && commonControlVersion >= 6)
2004
Debug.Assert(System.Environment.OSVersion.
Version
.Major < 6);
2075
Debug.Assert(System.Environment.OSVersion.
Version
.Major >= 6);
MS\Internal\AutomationProxies\WindowsButton.cs (3)
205
if (Environment.OSVersion.
Version
.Major < 6)
305
if (idEvent == InvokePattern.InvokedEvent && Environment.OSVersion.
Version
.Major >= 6)
575
if (Environment.OSVersion.
Version
.Major >= 6)
MS\Internal\AutomationProxies\WindowsListView.cs (1)
922
if (Environment.OSVersion.
Version
.Major < 6)
MS\Internal\AutomationProxies\WindowsMenu.cs (2)
829
if ((Environment.OSVersion.
Version
.Major < 6) && (Misc.IsLayoutRTL(_hwnd)))
1275
if ((Environment.OSVersion.
Version
.Major < 6) && (Misc.IsLayoutRTL(_hwnd)))
MS\Internal\AutomationProxies\WindowsScrollBar.cs (2)
177
if ((Environment.OSVersion.
Version
.Major < 6) && (Misc.IsLayoutRTL(_parent._hwnd)))
602
if ((Environment.OSVersion.
Version
.Major < 6) && (_sbFlag == NativeMethods.SB_HORZ) && (Misc.IsControlRTL(_parent._hwnd)))
MS\Internal\AutomationProxies\WindowsScrollBarBits.cs (2)
245
if ((Environment.OSVersion.
Version
.Major < 6) && (Misc.IsLayoutRTL(parent._parent._hwnd)))
426
if ((Environment.OSVersion.
Version
.Major < 6) && (Misc.IsLayoutRTL(hwnd)))
MS\Internal\AutomationProxies\WindowsTooltip.cs (1)
224
if (System.Environment.OSVersion.
Version
.Major >= 6)
MS\Internal\AutomationProxies\WindowsTreeView.cs (1)
828
if (_nativeAcc == null && System.Environment.OSVersion.
Version
.Major >= 6 && Misc.IsWindowInGivenProcess(_hwnd, "explorer"))
MS\Win32\UnsafeNativeMethods.cs (1)
329
if (System.Environment.OSVersion.
Version
.Major >= 6)
WindowsBase (2)
Base\MS\Internal\Utilities.cs (1)
18
private static readonly Version _osVersion = Environment.OSVersion.
Version
;
Shared\MS\Utility\Trace.cs (1)
137
if (Environment.OSVersion.
Version
.Major < 6 ||
WsatConfig (1)
Configuration\Utilities.cs (1)
34
get { return System.Environment.OSVersion.
Version
.Major; }
WsatUI (1)
Configuration\Utilities.cs (1)
34
get { return System.Environment.OSVersion.
Version
.Major; }