Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!uunet!crdgw1!brspyr1!jillj From: jillj@brspyr1.BRS.Com (Jill Jacomine) Newsgroups: comp.sys.ibm.pc Subject: HELP! Using DOS print Message-ID: <6534@brspyr1.BRS.Com> Date: 28 Nov 89 21:21:56 GMT Distribution: usa Organization: BRS Information Technologies; Latham, NY Lines: 29 I am trying to execute the DOS (version 3.1) print command from within an executable (compliled using MSC 5.1). The command I am using is: spawnvp(P_WAIT,"print.com",args); The value of args is "print /D:prn filename". Now, this works well enough to print the file out, the problem seems to be setting the device within the program eats up about 200k of memory, and never lets it go. (I tried setting the device before executing the program, and it seems to work fine, therefore I am relativly sure the problem is with the /D:prn option). A chkdsk before running the program shows 655360 bytes total memory and 594256 bytes free, after execution it is 426720 bytes total memory and 356616 bytes free. I have tried using the SYSTEM function, as well as different SPAWN functions, but they all yield the same results. Has anyone else come across this problem, or can anyone offer information as to why this happens and how it can be corrected. Thanks in advance. Jill Jacomine ------------------------------------------------------------------------------ ////////////////////////////////////////////////////////////////////////////// ------------------------------------------------------------------------------ Jill Jacomine (jill@brspyr1.BRS.COM) UUCP: BRS Information Technologies Latham, NY