Newsgroups : Borland : borland.public.delphi.nativeapi.win32 : 2005 Jul : "SET myvar=myDelphiConsole.exe -ini myini.ini -key titleName" batch script

www.cryer.info
Managed Newsgroup Archive

"SET myvar=myDelphiConsole.exe -ini myini.ini -key titleName" batch script

Subject:"SET myvar=myDelphiConsole.exe -ini myini.ini -key titleName" batch script
Posted by:"Whome" (noma..@nomai.com)
Date:Fri, 22 Jul 2005 09:46:29 +0300

[Win2000, Delphi6]
I am running out of ideas, skill and knowledge.

I have a batch script file and I want to set few env variables using a
console utility tool.

myDelphiConsole.exe is a console application and it writes a single to a
console screen (Write and WriteLn), its a sort of return value from
method. Value is then set to an environment variable and used in a
script file.

Is it just impossible to set dynamic envvar values from a console.exe
application "return" value?

- - -
The following pseudo example illustrates what I am looking for.
[missionImpossible.bat]
@echo off
SET count=myDelphiConsole.exe -ini myini.ini -key count
SET /A count=count/2
SET title=myDelphiConsole.exe -ini myini.ini -key titleName
ECHO %count%
ECHO %title%
myOtherConsole.exe -title %title% -count %count%
- - -

The following test.bat works fine, but does not give any dymanic values.
[test.bat]
@echo off
set count=10
set /A count=count/2
ECHO %count%
- - -

Glossary

File Types

Replies:

www.cryer.info
Managed Newsgroup Archive