Need some command line help - Techist - Tech Forum

Go Back   Techist - Tech Forum > Computer Software > Microsoft Windows and Software
Closed Thread
Thread Tools Display Modes
Old 06-03-2005, 07:52 PM   #1 (permalink)
Ultra Techie
Join Date: Nov 2004
Location: Socal
Posts: 665
Default Need some command line help

Ok short version first

I need to find a way to put the output of one program into the command line of another.

Dates.exe -> 6-3-2005
Zip *.html
output into
is basicly what I want to do

If that doesn't make sence heres the long version

I have a stat program that generates html files, now in order to sort them I want to use the date as a filename for the zip file. So I have a date program that outputs the right format and a command line archive utility(zip program). .... MY Problem is I can't figure out how to set a variable from a txt file or output of the Date program, or use the output of the Date program in the command line of the zip program.

If anyonw can help please do.

Sui is offline  
Old 06-05-2005, 12:53 PM   #2 (permalink)
Ultra Techie
Join Date: Nov 2004
Location: Socal
Posts: 665


Sui is offline  
Old 06-05-2005, 12:55 PM   #3 (permalink)
Monster Techie
Join Date: Feb 2005
Posts: 1,487

This might be better in another forum. I think the best solution would be Visual Basic but I'm not too good with that yet.
<font size=\"1\">Intel Pentium 4 3.4GHZ HT-------------------AMD Athlon 64 3000+ Winchester
Intel Stock CPU Cooler------------------------Zalman 7700-Cu
Idle: 51C---------------------------------------Idle: 21C
Load: 72C--------------------------------------Load: 28C
ASUS P4C800-E Deluxe-----------------------GIGABYTE K8NF4-9 NForce4 4X
512MBX2 Corsair XMS 2-2-2-5 PC-3200-----512MBX2 Corsair XMS 2-2-2-5 PC-3200
ATI RADEON X800 XT Platinum Edition-------ATI RADEON X800 XL
Creative Sound Blaster Audigy 2 ZS----------Creative Sound Blaster Audigy 2 ZS
Western Digital Raptor 37GB 10K------------2X Western Digital SATA150 Caviar SE 80GB RAID 0
Antec True 480W------------------------------Thermaltake Silent PurePower 680W
Zalman 5.1 Headphones----------------------Zalman 5.1 Headphones
Zalman High Sensitivity Microphone----------Zalman High Sensitivity Microphone
Microsoft Multimedia Keyboard 1.0A----------Logitech Media Keyboard
Microsoft Intellimouse Explorer 4.0A---------Logitech MX510
3DMark05: 5,928------------------------------3DMark05: 5,000</font>
dale5605 is offline  
Old 06-05-2005, 01:12 PM   #4 (permalink)
Master Techie
Join Date: Feb 2004
Posts: 2,172
Send a message via AIM to Win2kpatcher

I was thinking something along the lines of a nice perl script. Programming is my weakest link though. Perhaps Inaris will see this as he seems to be really in tune with scripting in perl.
Win2kpatcher is offline  
Old 06-05-2005, 04:39 PM   #5 (permalink)
Ultra Techie
Join Date: Nov 2004
Location: Socal
Posts: 665

Well if there was a Dos forum then I would have posted there, cause thats where this more or less belonged. I didn't want to post into programing forums because its not really programing, and I didn't want to piss them off.

Anyway I finally found a solution after about 12 different searches I found this. Basicly you put 'set var=' in one text file, and use the output function to make a 2nd text file, and use copy to merge the two files into a single batch file... that looks like 'set var=6-5' and tada set variable from output of another program.

date.exe m-d > date.txt

SET VARNAME=^Z (thats ctrl + z)

copy init.txt+date.txt varset.bat

I feel kind of stupid now that I battled with it for 3 days. I knew I was gonna feel stupid once I found the answer on day #1.
Sui is offline  
Closed Thread

Thread Tools
Display Modes

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 On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Our Communities

Our communities encompass many different hobbies and interests, but each one is built on friendly, intelligent membership.

» More about our Communities

Automotive Communities

Our Automotive communities encompass many different makes and models. From U.S. domestics to European Saloons.

» More about our Automotive Communities

Marine Communities

Our Marine websites focus on Cruising and Sailing Vessels, including forums and the largest cruising Wiki project on the web today.

» More about our Marine Communities

Copyright 2002-2015 Social Knowledge, LLC All Rights Reserved.

All times are GMT -5. The time now is 08:44 AM.

Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2016, vBulletin Solutions, Inc.