Thread: Calling one program from another

  1. #1
    Registered User
    Join Date
    Dec 2006
    Posts
    6

    Calling one program from another

    I have created a graphics app in turbo C in which I have created a window by using the bar() fucntion.In this application I am calling another application (another .c file) which shows a window(again created using the bar() function that accepts a file name(like the File Save box in Turbo C) .When I click an OK button(again created using the rectangle function) on this second window after inputting the file name , the second window should disappear leaving the first window(the parent window) intact.The second window is supposed to be displayed over the first window like in all applications that can open dialog boxes like File Open,File Save etc. I tried but when I dispose the second window, all the graphics on the screen gets erased.One way is to redraw all the graphics that were already present on the window after the second window has been disposed of.But thats very difficult especially if there are any text content on the screen.I have included the second file name by using the #include statement in the main file.Is there anyway I can do it? Thanks in advance..

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,661
    Sure, write a proper window manager which performs things like "save under" when you draw one dialog on top of another. So that when the 2nd dialog is removed, it can repair the 1st with what was saved.

    Might I ask why you're STILL using a stone-age compiler.

    > In this application I am calling another application (another .c file)
    This is not one application calling another, it is one function calling another.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. insufficient memory for tsr
    By manmohan in forum C Programming
    Replies: 8
    Last Post: 01-02-2004, 09:48 AM
  2. Date program starts DOS's date
    By jrahhali in forum C++ Programming
    Replies: 1
    Last Post: 11-24-2003, 05:23 PM
  3. calling programs from a c++ program
    By md4u in forum C++ Programming
    Replies: 0
    Last Post: 05-04-2003, 07:39 AM
  4. fopen();
    By GanglyLamb in forum C Programming
    Replies: 8
    Last Post: 11-03-2002, 12:39 PM
  5. calling c++ program from a webpage
    By Unregistered in forum C++ Programming
    Replies: 1
    Last Post: 10-04-2001, 09:41 AM