Questions tagged [windowsversion]

33 questions
44
votes
8 answers

How to get Windows version from command prompt or from PowerShell

But is there a way to get the exact version string using command line output similar to the one mentioned in the image? The attached is the output of "winver" command from run. PS: I am looking for a batch or PowerShell command. There are some…
Sandie
  • 869
  • 2
  • 12
  • 22
20
votes
7 answers

How can I determine the Windows version from a VB 6 app?

I want to detect any Windows versions from 95 to Win 7. I also would like to display if the OS is 32-bit or 64-bit. That's it; it's that simple. :) What code could I use to do this from within a VB 6 application?
SOF User
  • 7,590
  • 22
  • 75
  • 121
17
votes
6 answers

GetVersionEx under Windows 8

I'm writing a C++ code to determine what OS it is running on. I use GetVersionEx() API to do that, and this code as a tutorial, but it doesn't seems to handle Windows 8. Does anyone know how to fix it to run under Windows 8?
ahmd0
  • 16,633
  • 33
  • 137
  • 233
12
votes
6 answers

Getting Windows OS version programmatically

I am trying to fetch Windows version with C# on my Windows 10 machine. I always get those values (with C#\C++): Major: 6 Minor: 2 Which is Windows 8 OS, accordingly to MSDN C# code: var major = OperatingSystem.Version.Major var minor =…
Pavel Durov
  • 1,287
  • 2
  • 13
  • 28
11
votes
6 answers

How to check Windows edition in Java?

I want to check Windows edition (Basic or Home or Professional or Business or other) in Java. How do I do this?
lupchiazoem
  • 8,026
  • 6
  • 36
  • 42
10
votes
4 answers

Windows version in c#

I want to know which Windows version the PC has.. in C# Framework 3.5 I have tried using OperatingSystem os = Environment.OSVersion; Version ver = os.Version; But the result is Plataform: WIN32NT version 6.2.9200 Version minor: 2 Version Major:…
Diego
  • 2,238
  • 4
  • 31
  • 68
4
votes
1 answer

Problem with checking the Windows version from Inno Setup

My program installs a driver, which has different versions compiled for XP, Win2003, Vista/Win2008, and Win7. I use pascal functions to check which is the OS, and install the corresponding DLL. On some users' systems no DLL is installed, which…
sashoalm
  • 75,001
  • 122
  • 434
  • 781
3
votes
1 answer

What value should I use for OnlyBelowVersion in InnoSetup for Windows 2000 only?

I want to use OnlyBelowVersion to install the sc.exe program if the Windows version is 2000 and not at all for Windows NT and below. What is the only below version required for Windows 2000 only, ie what is the minimum windows XP or Windows 2003…
vfclists
  • 19,193
  • 21
  • 73
  • 92
3
votes
6 answers

Is it necessary to test my application on all Windows OS's AND all editions of each?

I will be testing an application that claims to run on Windows XP, Windows Vista, and Windows 7. I know that I have to test the application for each of those on 32-bit and 64-bit (if it exists), but I'm not sure if it's necessary to test each…
Brian T Hannan
  • 3,925
  • 18
  • 56
  • 96
3
votes
1 answer

Style WPF normal Control depending on Windows Theme

I have read lots of thing about WPF Theme, Skin, Style etc... But there is still something I cannot achieve. I have custom controls, which are styled depending on the OS theme, by having a different style in each of the theme file…
StrAbZ
  • 579
  • 1
  • 8
  • 24
2
votes
2 answers

List of Kernel32.dll versions that ship with various Windows versions?

I'm trying to find out the true Windows version. For some reason my Wise installer sometimes reports the an XP version # on Windows 7. One solution is to look at the kernel32.dll version as mentioned here: How to detect true Windows version? I'm…
Clay Nichols
  • 11,848
  • 30
  • 109
  • 170
2
votes
1 answer

Why is Winver showing another Version than Powershell?

Hello Guys! Why is Winver showing me Windows Version 21H2 but Powershell Command 2009? Get-ComputerInfo | select WindowsProductName, WindowsVersion Info: With my Personal PC at home Windows 11 Pro 21H2, it works with the command Get-ComputerInfo |…
Linne
  • 41
  • 3
2
votes
3 answers

Checking the Windows version

I want a code to be executed just for Windows-XP but I must check whether the current windows is Windows-XP or not. wxPlatformInfo windows = wxPlatformInfo::Get(); int winXP[] = { 5,1 }; int winXP64[] = { 5,2 }; if (windows.GetOSMajorVersion() ==…
Lion King
  • 32,851
  • 25
  • 81
  • 143
2
votes
3 answers

Identify Windows Editions

I am writing a function which prints out detailed Windows Version informations, the output may be a tuple like this: ('32bit', 'XP', 'Professional', 'SP3', 'English') It will be supporting Windows XP and above. And I'm stuck with getting the…
Wang Dingwei
  • 4,661
  • 6
  • 32
  • 43
2
votes
2 answers

How to do Conditional Compilation for CSIDL or KNOWFOLDERID in Delphi XE4?

I'm running Delphi XE4 on a Windows 7 machine. I'd like to have one code base that can recognize whether to use CSIDL or KNOWFOLDERID. Is there a way to use {$IFDEF XXXXXX) to conditionally compile different files in the uses section and to call…
1
2 3