General discussion

Locked

Pookin' for a bat file in all da wong pa

By Aaron_Wurthmann ·
Does any one have an OS checking batch file out there that I can borrow?

EXAMPLE:
Windows2000 will run these commands..
blah blah blah
WindowsNT will run these commands
ya ya ya ya
Windows98 or IF ELSE then run these commands
echo "WINDOWS 9x SUCKS!!!"

FIRST PERSON THAT SAYS USE KIXSART DIES!
(I didn't ask for kixtart, I asked for a batch file, you understand the difference)

This conversation is currently closed to new comments.

8 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

Pookin' for a bat file in all da wong pa

by termiNaTor In reply to Pookin' for a bat file in ...

KIXSTART

Just kidding, I couldn't help it

I will reasearch for an answer to your question

Good luck

Collapse -

Pookin' for a bat file in all da wong pa

by Aaron_Wurthmann In reply to Pookin' for a bat file in ...

that not funny.
=)

Collapse -

Pookin' for a bat file in all da wong pa

by McKayTech In reply to Pookin' for a bat file in ...

Since only the first person that suggests it dies, allow me to be the second: Kixtart.

Okay, now down to business. You can read the contents of the %comspec% environment variable and put it in an IF statement like this:

if exist "c:\windows\command.com" echo "Hey, this is Windows98!"
if exist "c:\winnt\system32\cmd.exe" echo "Nice doggie, you're running NT"
(obviously replace the echo statement with what you really want to do or say).

The problem with this is that MS uses the same OS description and comspec path for NT and W2K (same problem with Win95/Win9. So you'd be better off with something that can read a registry key to get the specific OS info. But I won't mention what program has that capability.

Or you can identify a file that is unique to each OS and use that in the If exist statement.

regards!

paul

Collapse -

Pookin' for a bat file in all da wong pa

by Aaron_Wurthmann In reply to Pookin' for a bat file in ...

Dude your the man, guess what I am delling with right now.. I DAMN DoS ATTACK.. life sucks for me right now. Thanks once again Paul.

Collapse -

Pookin' for a bat file in all da wong pa

LOL

Well so far I have discovered that Windows98 doesn't have an environment variable for the OS. BUT WindowsNT and Windows2000 do. It is os=windows_nt, okay so lets say that I go to all of the windows98 machines and set os=windows_98 to all of the machines. (no really I can do that) then how do I use the environment variable to my advantage in this scenario?

Collapse -

Pookin' for a bat file in all da wong pa

by Aaron_Wurthmann In reply to Pookin' for a bat file in ...
Collapse -

Pookin' for a bat file in all da wong pa

I really don't like Kixtart! I just can't seem to understand how to set up the damn thing on my network, and I don't like having the exe's on my client machines. I think that the readme suggests that you should.. any way.. I'll ask a question on a proper kixtart install some other time..

Paul you then man! I'll keep this question open incase anyone has any more ideas but here is what I am doing after reading your answer.

if exist "c:\windows\command.com" echo "Hey, this is Windows98!"
ifexist "C:\Documents and Settings\%username%" echo "Windows2000 rocks!"
if exist "c:\winnt\Profiles\%username%" echo "Nice doggie, you're running NT"

Collapse -

Pookin' for a bat file in all da wong pa

by Aaron_Wurthmann In reply to Pookin' for a bat file in ...
Back to Windows Forum
8 total posts (Page 1 of 1)  

Related Discussions

Related Forums