|
|
#1 |
|
Junior Member
Join Date: Nov 2005
Posts: 1
|
Question about a DOS command (yes DOS)
I had to do a quick and dirty installaion to repair a customer's fubar. I needed to check the windows version. I usually do not have to do this so I have not looked at the proper script.
Using the VER command, I wanted to put the os version into a text file. I tried to do this: ExecShell open "c:\ver.exe" "> test.txt" and then ExecShell open "c:\ver.exe > test.txt" (also tried "Exec") Neither worked (but NSIS did not gibe any errors) so I finally just copped out and used ExecShell open "C:\testing\a.bat" which did the trick. Not a big deal, but I was wondering why the first and the second bits of code did not work or cause an error at compile. |
|
|
|
|
|
#2 |
|
Debian user
(Forum King) Join Date: Jan 2003
Location: Arch land
Posts: 4,917
|
If you want to get Windows version, check the forum & the wiki for some functions
* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with MATE. * Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with MATE. |
|
|
|
|
|
#3 | |
|
Junior Member
Join Date: Nov 2005
Posts: 1
|
Re: Question about a DOS command (yes DOS)
Quote:
"cmd.exe /c ver > test.txt" Though I'm not 100% sure that the redirection would work. |
|
|
|
|
|
|
#4 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
Batch file is better way for compatibility with old Wins http://forums.winamp.com/showthread....84#post1803084
To hide DOS window and to redirect output to log file you can use ExecDos plug-in. Another way (not require output string parsing) - version plug-in http://nsis.sourceforge.net/Detect_Windows_Version |
|
|
|
|
|
#5 |
|
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
Or as already suggested use an NSIS function:
http://nsis.sourceforge.net/Docs/AppendixC.html#C.5 -Stu |
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|