Technology Questions

Go Back   Technology Questions > Software Questions > Operating System Questions > Vista Community > Windows Vista

Windows Vista Discuss the different versions of Windows Vista, Fuji, or Vienna

Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old 11-22-2007, 09:00 PM
DPM
Newsgroup Contributor
 
Posts: n/a
How to identify if the OS is Vista or higher

Hi,

Is there a way to know if the OS version is Vista or higher through a MS-DOS
batch
file ?

Following is a sample which I managed to do

Ver > OSVer.Txt
FIND "[Version 6." OSVer.Txt > NUL
IF ERRORLEVEL 1 ECHO OS is not Vista
IF NOT ERRORLEVEL 1 ECHO OS is Vista

The problems which I have regarding the above are,
- How to get the output from the VER command to a variable ? or is there any
other command ?
- Say if I send the output from VER to a text file how to know whether the
OS is Vista and above ?
(FIND only searches for a perticular text)

Please advise.


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

 
Old 11-22-2007, 09:00 PM
  #2 (permalink)  
Old 11-22-2007, 09:30 PM
Peter Foldes
Newsgroup Contributor
 
Posts: n/a
Re: How to identify if the OS is Vista or higher

You can always run a simple script

--
Peter

Please Reply to Newsgroup for the benefit of others
Requests for assistance by email can not and will not be acknowledged.

"DPM" <aa@bb.cc> wrote in message news:O65VRxYLIHA.4684@TK2MSFTNGP06.phx.gbl...[color=blue]
> Hi,
>
> Is there a way to know if the OS version is Vista or higher through a MS-DOS
> batch
> file ?
>
> Following is a sample which I managed to do
>
> Ver > OSVer.Txt
> FIND "[Version 6." OSVer.Txt > NUL
> IF ERRORLEVEL 1 ECHO OS is not Vista
> IF NOT ERRORLEVEL 1 ECHO OS is Vista
>
> The problems which I have regarding the above are,
> - How to get the output from the VER command to a variable ? or is there any
> other command ?
> - Say if I send the output from VER to a text file how to know whether the
> OS is Vista and above ?
> (FIND only searches for a perticular text)
>
> Please advise.
>
>[/color]
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #3 (permalink)  
Old 11-22-2007, 10:30 PM
DPM
Newsgroup Contributor
 
Posts: n/a
Re: How to identify if the OS is Vista or higher

Thanks.
Any ideas on how I can do this ? Some sort of clue or example would help.
Do I need to create an exe using a programming language ?


"Peter Foldes" <okf22********.com> wrote in message
news:%23E$EGEZLIHA.5208@TK2MSFTNGP04.phx.gbl...
You can always run a simple script

--
Peter

Please Reply to Newsgroup for the benefit of others
Requests for assistance by email can not and will not be acknowledged.

"DPM" <aa@bb.cc> wrote in message
news:O65VRxYLIHA.4684@TK2MSFTNGP06.phx.gbl...[color=blue]
> Hi,
>
> Is there a way to know if the OS version is Vista or higher through a
> MS-DOS
> batch
> file ?
>
> Following is a sample which I managed to do
>
> Ver > OSVer.Txt
> FIND "[Version 6." OSVer.Txt > NUL
> IF ERRORLEVEL 1 ECHO OS is not Vista
> IF NOT ERRORLEVEL 1 ECHO OS is Vista
>
> The problems which I have regarding the above are,
> - How to get the output from the VER command to a variable ? or is there
> any
> other command ?
> - Say if I send the output from VER to a text file how to know whether the
> OS is Vista and above ?
> (FIND only searches for a perticular text)
>
> Please advise.
>
>[/color]


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #4 (permalink)  
Old 11-23-2007, 06:10 AM
Peter Foldes
Newsgroup Contributor
 
Posts: n/a
Re: How to identify if the OS is Vista or higher

DPM

Since this is a Vista newsgroup and putting a script within a post would not be appropriate for some frequenting this group, may I suggest that you repost this to the scripting newsgroup

news:\\msnews.microsoft.com\microsoft.public.windows.server.scripting


--
Peter

Please Reply to Newsgroup for the benefit of others
Requests for assistance by email can not and will not be acknowledged.

"DPM" <aa@bb.cc> wrote in message news:OyOfLnZLIHA.5764@TK2MSFTNGP06.phx.gbl...[color=blue]
> Thanks.
> Any ideas on how I can do this ? Some sort of clue or example would help.
> Do I need to create an exe using a programming language ?
>
>
> "Peter Foldes" <okf22********.com> wrote in message
> news:%23E$EGEZLIHA.5208@TK2MSFTNGP04.phx.gbl...
> You can always run a simple script
>
> --
> Peter
>
> Please Reply to Newsgroup for the benefit of others
> Requests for assistance by email can not and will not be acknowledged.
>
> "DPM" <aa@bb.cc> wrote in message
> news:O65VRxYLIHA.4684@TK2MSFTNGP06.phx.gbl...[color=green]
>> Hi,
>>
>> Is there a way to know if the OS version is Vista or higher through a
>> MS-DOS
>> batch
>> file ?
>>
>> Following is a sample which I managed to do
>>
>> Ver > OSVer.Txt
>> FIND "[Version 6." OSVer.Txt > NUL
>> IF ERRORLEVEL 1 ECHO OS is not Vista
>> IF NOT ERRORLEVEL 1 ECHO OS is Vista
>>
>> The problems which I have regarding the above are,
>> - How to get the output from the VER command to a variable ? or is there
>> any
>> other command ?
>> - Say if I send the output from VER to a text file how to know whether the
>> OS is Vista and above ?
>> (FIND only searches for a perticular text)
>>
>> Please advise.
>>
>> [/color]
>
>[/color]
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

  #5 (permalink)  
Old 11-23-2007, 06:30 AM
DPM
Newsgroup Contributor
 
Posts: n/a
Re: How to identify if the OS is Vista or higher

Thanks.


"Peter Foldes" <okf22********.com> wrote in message
news:%23aNi0ldLIHA.4688@TK2MSFTNGP06.phx.gbl...
DPM

Since this is a Vista newsgroup and putting a script within a post would not
be appropriate for some frequenting this group, may I suggest that you
repost this to the scripting newsgroup

news:\\msnews.microsoft.com\microsoft.public.windows.server.scripting


--
Peter

Please Reply to Newsgroup for the benefit of others
Requests for assistance by email can not and will not be acknowledged.

"DPM" <aa@bb.cc> wrote in message
news:OyOfLnZLIHA.5764@TK2MSFTNGP06.phx.gbl...[color=blue]
> Thanks.
> Any ideas on how I can do this ? Some sort of clue or example would help.
> Do I need to create an exe using a programming language ?
>
>
> "Peter Foldes" <okf22********.com> wrote in message
> news:%23E$EGEZLIHA.5208@TK2MSFTNGP04.phx.gbl...
> You can always run a simple script
>
> --
> Peter
>
> Please Reply to Newsgroup for the benefit of others
> Requests for assistance by email can not and will not be acknowledged.
>
> "DPM" <aa@bb.cc> wrote in message
> news:O65VRxYLIHA.4684@TK2MSFTNGP06.phx.gbl...[color=green]
>> Hi,
>>
>> Is there a way to know if the OS version is Vista or higher through a
>> MS-DOS
>> batch
>> file ?
>>
>> Following is a sample which I managed to do
>>
>> Ver > OSVer.Txt
>> FIND "[Version 6." OSVer.Txt > NUL
>> IF ERRORLEVEL 1 ECHO OS is not Vista
>> IF NOT ERRORLEVEL 1 ECHO OS is Vista
>>
>> The problems which I have regarding the above are,
>> - How to get the output from the VER command to a variable ? or is there
>> any
>> other command ?
>> - Say if I send the output from VER to a text file how to know whether
>> the
>> OS is Vista and above ?
>> (FIND only searches for a perticular text)
>>
>> Please advise.
>>
>>[/color]
>
>[/color]


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Reply

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is Off
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Vista does not identify Secondary monitor eveneden Vista Hardware 34 04-12-2007 06:37 PM
Vista Retail Sales Higher than Expected ! FireWall2 Windows Vista 0 01-12-2007 01:31 PM


New To Technology Questions? Do You Need Help with Your Computer or Device? Do You Need Help with this site?

All times are GMT -8. The time now is 07:03 PM.


2003 - 2009 All Rights Reserved. Technology Questions

Search Engine Friendly URLs by vBSEO 3.3.0