Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!uwm.edu!bionet!agate!ucbvax!bloom-beacon!mit-eddie!uw-beaver!zephyr.ens.tek.com!vice!bobb From: bobb@vice.ICO.TEK.COM (Bob Beauchaine) Newsgroups: comp.lang.pascal Subject: Re: DOS Environment Variables Message-ID: <7333@vice.ICO.TEK.COM> Date: 22 Apr 91 16:16:23 GMT References: <4744@ash54.UUCP> Reply-To: bobb@vice.ICO.TEK.COM (Bob Beauchaine) Distribution: comp Organization: Tektronix, Inc., Beaverton, OR. Lines: 24 In article <4744@ash54.UUCP> hamilton@motcid.UUCP (Danial Hamilton) writes: >My son programs using Turbo Pascal, and would like to pass >a value from his Pascal program to another program via a >DOS environment variable. Can he do this? Can someone >tell him how? He knows how to set the errorlevel, and could >accomplish his goal that way, but it is not as elegant of a >solution as he would like. Any help out there? The discussion on permanently changing an environment variable was on this group some time ago; sorry, I can't refer you to an article, but perhaps someone else can. Be warned; the topic is probable more advanced than you think. Another scenario you might consider is using the Dos interprocess communication area. Any good text on the inner workings of MS-DOS will contain an explanation. The one I know of is Peter_Norton's_ Guide_to_the_IBM_PC. /\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\ Bob Beauchaine bobb@vice.ICO.TEK.COM C: The language that combines the power of assembly language with the flexibility of assembly language.