Path: utzoo!utgpu!watserv1!ria!uwovax!7103_2622 From: 7103_2622@uwovax.uwo.ca (Eric Smith) Newsgroups: comp.sys.atari.st.tech Subject: Re: PS problem, and DA problem!!! Message-ID: <7106.26fcfbec@uwovax.uwo.ca> Date: 23 Sep 90 22:16:12 GMT References: <2384.26fca905@miavx1.acs.muohio.edu> Lines: 25 In article <2384.26fca905@miavx1.acs.muohio.edu>, rlcollins@miavx1.acs.muohio.edu (Ryan 'Gozar' Collins) writes: > 2. Also, I am writing a DA that needs to know if there is a program > running or not. Is there an easy way to check this? > There's always a program running (the GEM DESKTOP is just an ordinary TOS program, loaded from ROM instead of from disk). If you mean, "is the currently running program not the desktop", you might try the shel_read AES call: char pgmname[128], cmdline[128]; if (shel_read(pgmname, cmdline) == 0) printf("an error occured\n"); else printf("the desktop thinks %s is the currently running program\n", pgmname); Note also that the desktop's idea of what the current program is may not correspond to reality, since if a program run from the desktop runs another program, there's no way for the desktop to know. -- Eric R. Smith email: Dept. of Mathematics ersmith@uwovax.uwo.ca University of Western Ontario ersmith@uwovax.bitnet London, Ont. Canada N6A 5B7 ph: (519) 661-3638