top_left top_right
bottom_left
Next Event: Unknown | Forum Rules | QGL Website | Event Registration
openFolder AusForums.com
iconwatfolderLineopenFolder LANs
iconwatfolderLineopenFolder QGL
iconwatfolderLineopenFolder QGL Forum
Author
Topic: DOS batch file help
Space Ninja
Posts: 3260
Location: Brisbane, Queensland
Hey guys,

I'm just trying to write a small batch file here at the moment, but was wondering if anybody could help me out with a couple of problems I'm having.

I'm trying to create a file which a user can run on their desktop, which puts a bunch of system relevant information into a text file and displays it back to them.

What I'd like to do is write a batch file which grabs %username% and %computername% and dumps them to c:\computerinfo.txt and then executes notepad and displays it back to the user. I'm fine with all the variables etc but I'm wondering if anybody knows a way to pump the data from the raw command line to a text file? I thought it was something like | or print but I cannot remember and all the resources I find at the moment are for linux.

On the same topic too, does anybody know the % variable for finding an IP address??

Thanks in advance if you can help me out or point me in the right direction!
system
--
Jim
Posts: 4241
Location: Brisbane, Queensland
redirect: >
redirect append: >>

there's no variable I'm aware of for your ip addresses, but: http://www.ericphelps.com/batch/samples/ip.txt
Space Ninja
Posts: 3261
Location: Brisbane, Queensland
champion!

thanks jim!!
whoop
Posts: 9948
Location: Brisbane, Queensland

ipconfig >> ip.txt replace ip.txt with the name of your text file that you have the other crap in

last edited by whoop at 18:14:50 19/Apr/06
system
--
Not a new post since your last visit.
New Post Since your last visit
Back To Forum
Advertise with Us | Privacy Policy | Contact Us
© Copyright 2001-2026 AusGamers Pty Ltd. ACN 093 772 242.
Hosted by Mammoth Networks - Australian VPS Hosting
Web development by Mammoth Media.