A-Z List


Ver

Updated: April 17, 2012

Applies To: Windows 7, Windows Server 2000, Windows Server 2003, Windows Server 2003 R2, Windows Server 2003 with SP1, Windows Server 2003 with SP2, Windows Server 2008, Windows Server 2008 R2, Windows Vista, Windows XP

Displays the operating system version number.

For examples of how to use this command, see Examples.

Syntax

ver
Parameters

 

Parameter Description

/?

Displays help at the command prompt.

Examples

To obtain the version number of the operating system, type:

ver

Additional references

Command-Line Syntax Key

Tags :


Community Content

Drewfus
An enhanced ver command
<p>Apologies to AdrinS. The switches listed above are not available with the ver command in any version of Windows. Instead they are part of my wish list for the ver command.<br /></p> <p> <mtps:InstrumentedLink NavigateUrl="http://forum.sysinternals.com/forum_posts.asp?TID=23137&amp;title=extended-ver-command" runat="server" xmlns:mtps="http://msdn2.microsoft.com/mtps">http://forum.sysinternals.com/forum_posts.asp?TID=23137&amp;title=extended-ver-command</mtps:InstrumentedLink> <br /> </p> <p> </p>
Tags :

AdrinS
Changes?
Looks like this command has changed a lot.&nbsp; I can't get any of the switches to work with windows XP or windows 7. <br />
Tags :

Drewfus
How about some switches?
<pre>/csd [/e] Returns service pack level<br /> Ex: Service Pack 1<br />/build [/e] Returns build number<br /> Ex: 7100<br />/type Returns build type<br /> Ex: Multiprocessor Free<br />/cv Returns version number in Major.Minor format<br /> Ex: 6.1<br />/name Returns product name<br /> Ex: Windows Vista (TM) Ultimate<br />/lang [/e] Language version number, name &amp; TLA<br /> Ex: 1033 English - United States ENU<br />/lcid [/e[:x]] [/ra] Get Locale ID info<br /> Ex: en-ca 0x1009 4105<br />/format [/e[:x]] [/ra] Get User Locale info<br />/sku [/e] Stock Keeping Unit number and name<br /> Ex: 6 Business Edition<br />/eid Returns EditionID data<br /> Ex: Professional OEM 0<br />/office [/apps] [/e] Returns info on installed Office version<br /> Ex: 12 SP2 2007 Enterprise 1033<br />/dotnet .Net Framework versions, SP level &amp; lang<br /> Ex:<br /> 2.0 SP2 1033<br /> 3.0 SP2 1033<br /> 3.5 SP1 1033<br />/dx [/e] DirectX version<br /> Ex: 11<br />/ie [/csd] Internet Explorer info<br /> Ex: 8.0<br />/all Creates mini report<br />/file [path\]filename Returns file version<br />&lt;switch&gt; /e Sets exitCode as returned value<br />&lt;switch&gt; /ra Returns values for Reserved Accounts instead of CU<br /></pre> <p> <br />Get version of offline Windows installation:<br /></p> <pre>ver /cv /offwindir=&lt;offline windows directory&gt;</pre> <p> <br />Use a for /F loop to get offline version into envar:<br /></p> <pre>for /f %i in ('ver /cv /offwindir=d:\windows') do @set offCV=%i</pre> <p> <br />Use this environment variable to determine what operations should be run on offline system:<br /></p> <pre>if %offCV% geq 6.0 sfc /scannow /offbootdir=d:\ /offwindir=d:\windows</pre> <p> <br />Could be useful in WinPE.<br /><br />Get LCID string value into envar and use this to copy MUI files from and to appropriate folders:<br /></p> <pre>for /F %A in ('ver /lcid /ra') do @set LCIDstr=%A<br />copy %windir%\System32\certutil.exe D:\WinPE\mount\Windows\System32<br />copy C:\Windows\System32\%LCIDstr%\certutil.exe.mui D:\WinPE\mount\Windows\System32\%LCIDstr%<br /></pre> <p> <br />Save operating system version to master environment for future use:</p> <pre>for /f "tokens=1,2" %i in ('ver /cv /build') do @setx OS_Version %i.%j /m</pre> <p> <br />Get file version:<br /></p> <pre>ver /file %programfiles%\Microsoft Silverlight\sllauncher.exe<br />3.0.50106.0</pre> <p> <br />Get version info for remote system:<br /></p> <pre>ver <mtps:InstrumentedLink NavigateUrl="file://server/" runat="server" xmlns:mtps="http://msdn2.microsoft.com/mtps">\\Server</mtps:InstrumentedLink> /all</pre>
Tags : contentbug

Page view tracker