home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / database / informix / 3087 < prev    next >
Encoding:
Internet Message Format  |  1993-01-28  |  2.7 KB

  1. Path: sparky!uunet!ukma!gatech!emory!emory!not-for-mail
  2. From: jparker@hpbs2561.boi.hp.com (Jack Parker)
  3. Newsgroups: comp.databases.informix
  4. Subject: screen flashing (fwd)
  5. Date: 28 Jan 1993 19:33:14 -0500
  6. Organization: Mailing List Gateway
  7. Lines: 69
  8. Sender: walt@mathcs.emory.edu
  9. Distribution: world
  10. Message-ID: <1k9u0aINNjk4@emory.mathcs.emory.edu>
  11. Reply-To: jparker@hpbs2561.boi.hp.com (Jack Parker)
  12. NNTP-Posting-Host: emory.mathcs.emory.edu
  13. X-Informix-List-ID: <list.1832>
  14.  
  15. Quoting a whole lot of people(s):
  16.  
  17. > Jack,
  18. > Just saw your second posting on screen flashing hit the mailing list (I've
  19. > GOT* to get out of here!).  Anyway I hadn't posted anything to the list on
  20. > it because I vaguely (sp?) recalled seeing something on the list a while back
  21. > on the subject, and I was too lazy to look it up so I wouldn't appear too
  22. > dumb.  When I saw you quoting me, I figured I better do some checking.
  23. > Anyway, I grepped around in the archive and found the following messages from
  24. > December of 1991 (some of the headers are in an old style):
  25. > | 
  26. > | From: dave@das13.snide.com (Dave Snyder)
  27. > | 
  28. > | > Does anyone know if there is a way to run a unix command without the 
  29. > | > screen blinking/Flashing in Informix 4gl ?
  30. > | > 
  31. > | What we did was to call a C function that executes a "system" on the passed
  32.                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  33. > | in string.
  34.  
  35. Much stuff deleted...
  36.  
  37. Thank you Walt ! - and Dave and others.
  38.  
  39. enclosed is same c routine:
  40.  
  41. ______________________________________________________________________________
  42. /*
  43. run_cmn - run an OS command.  To replace the 4GL RUN command which clears
  44. the screen.  syntax is CALL run_cmn(command, length(command)+1) returning int
  45. */
  46.  
  47. run_cmd(arg)
  48. {
  49. char    cmd[80];
  50. int     siz, retcode;
  51.  
  52.    popint(&siz);                        
  53.    popquote(cmd,siz);
  54.    retcode=system(cmd);
  55.  
  56.    retint(retcode);
  57.  
  58.    return(1);
  59. }
  60. _____________________________________________________________________________
  61.  
  62.  
  63. Works like a champ. 
  64.  
  65. On the same subject.  If you display directly to the screen with a 
  66. 'DISPLAY string', it will clear the screen to display your string.
  67.  
  68. If you 'DISPLAY string AT y,x' it will work fine.
  69.  
  70. (Caused me heartache as I tested the return code by 'DISPLAY retcode' just
  71. after my OS call - thought we had the wrong solution)
  72.  
  73.  
  74. Again, much obliged.
  75. j.
  76. _____________________________________________________________________________
  77. Jack Parker - Contractor               |    "I wanna walk like you
  78. Hewlett Packard, BSMC Boise, Idaho, USA|         talk like you
  79. jparker@hpbs2651.boi.hp.com            |           toooooooo."
  80. (208) 323-5388 (W)  (208) 384-1623 (H) |                   - King Louie
  81. _____________________________________________________________________________
  82.