Specialty Forums
Security and Virus
General Hardware
CPUs/Overclocking
Networking
Digital Photo/Video
Office Software
PC Gaming
Console Gaming
Programming
Database
Web Development
Digital Home

General Forums
Windows XP
Windows Vista
Windows 95/98
Windows Me
Windows NT
Windows 2000
Win Server 2008
Win Server 2003
Windows 3.1
Linux
PDAs
BeOS
Novell Netware
OpenVMS
Solaris
Disk Op. System
Unix
Mac
OS/2

Drivers
Driver Scan
Driver Forum

Software
Automatic Updates

BIOS Updates

My Computing.Net

Solution Center

Free IT eBook

Howtos

Site Search

Message Find

RSS Feeds

Install Guides

Data Recovery

About

Home
Reply to Message Icon Go to Main Page Icon

How to store and retrieve values?

Original Message
Name: albert2u
Date: June 20, 2007 at 19:40:10 Pacific
Subject: How to store and retrieve values?
OS: Windows2000
CPU/Ram: Pentium Xeon
Model/Manufacturer: Dell
Comment:
Hi,

I had wrote some lines to get the user inputs in win2k dos prompt. But how can i store in a temp file and retrieve it and pass it in to another batch file for anohter process?

@echo off
set INPUT=
set /P INPUT=Type input: %=%
set /P INPUT2=Type input: %=%
if "%INPUT%"=="" goto input
echo Your input was: %INPUT%
if "%INPUT2%"==""goto input
echo Your input2 was: %INPUT2%

Can anyone help me in this. Appreciated very much.


Report Offensive Message For Removal


Response Number 1
Name: Mechanix2Go
Date: June 21, 2007 at 02:59:11 Pacific
Subject: How to store and retrieve values?
Reply: (edit)
[1] I don't see the label it's trying to GOTO.

[2] Once you've got the vars set, thay are available to other processes. Do you need them in FILEs?


=====================================
If at first you don't succeed, you're about average.

M2



Report Offensive Follow Up For Removal

Response Number 2
Name: albert2u
Date: June 21, 2007 at 03:17:08 Pacific
Subject: How to store and retrieve values?
Reply: (edit)
m2,sorry about that, actually i will need to call anohter batch file.

@echo off
set INPUT=
set /P INPUT=Type input: %=%
set /P INPUT2=Type input: %=%
if "%INPUT%"=="" goto input
echo Your input was: %INPUT%
if "%INPUT2%"==""goto input
echo Your input2 was: %INPUT2%
Call process.bat

One question, if i do not want to store the values into a temp file. Can i just pass the captured values directly to another batch?

If it can't pass it like that, then i will need to store in a File.

Tqvm.

albert2u


Report Offensive Follow Up For Removal

Response Number 3
Name: Mechanix2Go
Date: June 21, 2007 at 03:26:04 Pacific
Subject: How to store and retrieve values?
Reply: (edit)
::== bat1.bat
set name=abc
call bat2.bat
::==

::== bat2.bat
@echo the name is %name%
::==



=====================================
If at first you don't succeed, you're about average.

M2



Report Offensive Follow Up For Removal

Response Number 4
Name: albert2u
Date: June 22, 2007 at 01:24:01 Pacific
Subject: How to store and retrieve values?
Reply: (edit)
M2,

Thanks!
It works!

albert2u


Report Offensive Follow Up For Removal




Use following form to reply to current message:

   Name: From My Computing.Net Settings
 E-Mail: From My Computing.Net Settings

Subject: How to store and retrieve values?

Comments:

 
  Homepage URL (*): 
Homepage Title (*): 
         Image URL: 
 


Data Recovery Software




DSHUB24 Connection Problems

need help with dsl and dial up

novel 3.12

help mandriva install last straw!

Icon Scaling in Explorer Bar


The information on Computing.Net is the opinions of its users. Such opinions may not be accurate and they are to be used at your own risk. Computing.Net cannot verify the validity of the statements made on this site. Computing.Net and Computing.Net, LLC hereby disclaim all responsibility and liability for the content of Computing.Net and its accuracy.
PLEASE READ THE FULL DISCLAIMER AND LEGAL TERMS BY CLICKING HERE

All content ©1996-2007 Computing.Net, LLC