Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Clipper > Re: Environment...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 9 of 13 Topic 3878 of 3953
Post > Topic >>

Re: Environment Space in XP

by dlzc <dlzc1@[EMAIL PROTECTED] > Apr 8, 2008 at 07:21 AM

Dear Alan Secker:

On Apr 7, 6:06=A0pm, "Stephen Quinn" <stevej...@[EMAIL PROTECTED]
>
wrote:
> Alan
>
> As soon as you 'run' your batch file the 'Shell'
> containing those settings is closed when the batch
> file exits - that's why you don't see anything.
>
> The way it works is
> 1: Current DOS window (Parent)
> 2: Run batch file (creates a child shell with all
>    your new variables), nothing executed by batch
>    file the shell closes
> 3: On closing it returns to parent shell whose
>    environment didn't have the variables
>
> You cannot set up a DOS environment like that
> unless you execute an app that will use the shell
> that was just created Eg Norton Commander, XTree,
> etc... ).

Just to guild the lilly a bit...
When a batch file is called, a new invocation of cmd.exe or
command.com is executed with *a copy* of the environment as it existed
at the time of the call.  Any changes to the environment of the batch
file, affect only the batch file (and any children it calls), and are
discarded by the OpSys when the batch file terminates.  Essentially
all the environment variables are passed "by value", rather than "by
reference".

Just so the reason why this did not work is clear...

David A. Smith
 




 13 Posts in Topic:
Environment Space in XP
Alan Secker <alan@[EMA  2008-04-05 22:34:25 
Re: Environment Space in XP
"Ron Pinkas" &l  2008-04-05 17:53:14 
Re: Environment Space in XP
Alan Secker <alan@[EMA  2008-04-06 21:02:35 
Re: Environment Space in XP
"N:dlzc D:aol T:com   2008-04-06 13:46:00 
Re: Environment Space in XP
Alan Secker <alan@[EMA  2008-04-07 22:10:02 
Re: Environment Space in XP
"Stephen Quinn"  2008-04-08 01:06:20 
Re: Environment Space in XP
Alan Secker <alan@[EMA  2008-04-08 18:44:59 
Re: Environment Space in XP
"AUGE_OHR" <  2008-04-08 22:54:42 
Re: Environment Space in XP
dlzc <dlzc1@[EMAIL PRO  2008-04-08 07:21:36 
Re: Environment Space in XP
Alan Secker <alan@[EMA  2008-04-08 19:32:50 
Re: Environment Space in XP
Alan Secker <alan@[EMA  2008-04-09 09:46:37 
Re: Environment Space in XP
aardvark <aardvark@[EM  2008-04-06 20:40:55 
Re: Environment Space in XP
"Stephen Quinn"  2008-04-07 05:08:08 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Wed Jul 9 1:44:52 CDT 2008.