Thread: Convirt my C program to a GUI application/Web Application

  1. #1
    Registered User
    Join Date
    May 2008
    Posts
    134

    Convirt my C program to a GUI application/Web Application

    I have a C source file which takes two image file as its input as command line arg and one image file as output. I have developed the C program on linux now I want to develope a windows application using that c source with two inputs (Type = file) and one output file displayed. What should I do? what to implement? Visual studio 2005 can serve the purpose?

  2. #2
    Deathray Engineer MacGyver's Avatar
    Join Date
    Mar 2007
    Posts
    3,210
    You can use Visual Studios to develop a GUI, but you don't need to use that.

    As a warning, Windows programming -- and GUI programming in C -- is quite a different ballgame than standard console programming. You might be best off using a GUI library that will make your program more portable.

  3. #3
    Registered User
    Join Date
    May 2008
    Posts
    134
    plz let me know exactly what can i do to make the program more robust/prtable on the Linux platform?--Keeping in mind of the C source text file is developed, I won't like to change the code there.

  4. #4
    Deathray Engineer MacGyver's Avatar
    Join Date
    Mar 2007
    Posts
    3,210
    How do you intend to make your program into a GUI program from a console program without changing the source? More than likely you'll have to change something unless you thought exactly how you were going to interface the GUI code and the rest of the code.

    You can try using GTK+, or a number of other libraries. Search for one via google or elsewhere that fits your need.

  5. #5
    Jack of many languages Dino's Avatar
    Join Date
    Nov 2007
    Location
    Chappell Hill, Texas
    Posts
    2,332
    Quote Originally Posted by MacGyver View Post
    How do you intend to make your program into a GUI program from a console program without changing the source? More than likely you'll have to change something unless you thought exactly how you were going to interface the GUI code and the rest of the code.
    If it were me, I would write a front-end GUI wrapper that gathered the input from the user and then called the original program as a command line program. That way, no changes are needed to the original. That could be done simply in Visual Basic.
    Mainframe assembler programmer by trade. C coder when I can.

  6. #6
    Deathray Engineer MacGyver's Avatar
    Join Date
    Mar 2007
    Posts
    3,210
    Yes, as long as the GUI doesn't need to receive information from the console programs, that is fine, and, I suppose, probably what the OP is thinking.

  7. #7
    Registered User
    Join Date
    May 2008
    Posts
    134

    How to make the GUI Wrapper

    How to make the GUI Wrapper using Visual Basic?
    I have microsoft Visual Studio 2005.
    Say my program in c is named as myprogram.c and in linux i compile program as:
    ./a.out 1st.bmp 2nd.bmp output.bmp
    .................................................. .................................................. ...........................
    Last edited by kapil1089thekin; 07-21-2008 at 01:46 AM.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 18
    Last Post: 05-26-2008, 11:23 PM
  2. Using C++ for GUI with Database Application
    By bugmenot in forum Windows Programming
    Replies: 7
    Last Post: 12-14-2005, 08:24 PM
  3. Date program starts DOS's date
    By jrahhali in forum C++ Programming
    Replies: 1
    Last Post: 11-24-2003, 05:23 PM
  4. How To Convert A Dos-Prompt C++ PRogram Into Win32 Application ?
    By SonicWave in forum Windows Programming
    Replies: 1
    Last Post: 09-15-2001, 11:03 AM
  5. My program, anyhelp
    By @licomb in forum C Programming
    Replies: 14
    Last Post: 08-14-2001, 10:04 PM

Tags for this Thread