Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utgpu!water!watmath!clyde!rutgers!sunybcs!boulder!hao!noao!stsci!barsh From: barsh@stsci.UUCP Newsgroups: comp.os.vms Subject: Re: VAX C! Help me!! Message-ID: <99@obi-wan> Date: Thu, 12-Nov-87 10:40:00 EST Article-I.D.: obi-wan.99 Posted: Thu Nov 12 10:40:00 1987 Date-Received: Sat, 14-Nov-87 15:00:10 EST References: <3297@xanth.UUCP> Organization: Space Telescope Science Institute, Baltimore, MD 21218 Lines: 29 in article <3297@xanth.UUCP>, manes@xanth.UUCP (Mark Manes) says: > > I have a problem folks, I have just installed VAX C, on VMS 4.6. > > I want to call LIB$SPAWN and can't find a decent example, this program > that I am uploading does not work, however does compile, would someone > be so kind as to show me where I have messed up? The following is a working example: #include #include #include main() { $DESCRIPTOR (command_text, "show users"); $DESCRIPTOR (output_file, "disk.dat"); int status; if ((status = LIB$SPAWN(&command_text, 0, &output_file)) != SS$_NORMAL) printf("Command Failed %d\n",status); } jrbii ~~~~~