Thread: Please help me build a GUI application...

  1. #1
    Registered User khpuce's Avatar
    Join Date
    May 2003
    Posts
    165

    Please help me build a GUI application...

    Hi everyone,

    Now I've become pretty much comfortable with programming in C. Recently, I created a simple stock control application. Basically, this program loads/saves data from text/binary files, add/edit/delete items, display stock, keeps/saves transaction records in text file etc. However, it is a dos based program where all the operations are performed through menus/submenus by keyboard inputs.

    What I am trying to do now is to work with it further and make it a GUI application. I know that using Borland C++ Builder I can build GUI applications. But I've never used C++ Builder before and I am not sure whether I can use my existing C codes or I have to write it all again from scratch

    Any directions please ?

    Thank you.

    P.S. In case you want to know more...This is just a starting point. Eventually, step by step, I want to make it a complete working application with more complex functionalities like using a database (MS Access???) instead of simple text/binary datafiles, displaying graphs, adding network support etc. etc.

  2. #2
    Registered User khpuce's Avatar
    Join Date
    May 2003
    Posts
    165

    Question

    I don't know why there is no reply yet but I can only guess that perhaps my question was not clear enough

    So here it is again...

    1) I know that I can create a GUI application (like employee records database or stock control systems) using VB and MS Access. However, I want to use C instead of VB as I am more comfortable with C. The question is, can I use C with MS Access ? or are there better alternatives to create such application?

    2) I've heard something called C wrapper classes(?). Does it have anything to do with creating GUI's with C codes? If I want to use C codes instead of C++ codes (as I haven't done much C++ coding), will it make my life harder to create a GUI application with borland C++ builder?

    Thank you again everyone


    P.S. Please forgive me if my questions are really stupid

  3. #3
    Registered User
    Join Date
    Jul 2003
    Posts
    450
    No. I do not work with dos.

  4. #4
    pronounced 'fib' FillYourBrain's Avatar
    Join Date
    Aug 2002
    Posts
    2,297
    if I understand you correctly, you need to look at Win32 API development. The book is called "Programming Windows" by Charles Petzold. Get it and read it.
    "You are stupid! You are stupid! Oh, and don't forget, you are STUPID!" - Dexter

  5. #5
    Registered User khpuce's Avatar
    Join Date
    May 2003
    Posts
    165
    Quote Originally Posted by FillYourBrain
    if I understand you correctly, you need to look at Win32 API development. The book is called "Programming Windows" by Charles Petzold. Get it and read it.
    I guess your understanding is absolutely correct

    Thanks for the direction


    P.S Any suggestion for a suitable IDE ?

  6. #6
    Registered User mitakeet's Avatar
    Join Date
    Jun 2005
    Location
    Maryland, USA
    Posts
    212
    If you can get it, Microsoft's Visual C++ compiler is quite nice and it comes with MFC (Microsoft's Foundation Classes) that help in GUI building. MFC is more or less superceeded with .Net and there are other GUI builders for C/C++, not to mention other things entirely such as Visual Basic. DevC++ is a decent free compiler that will work fine, but has no easy GUI tools and won't compile MFC or .Net, but will compile raw Windows API GUI code. If you are serious about your application, abstract the database connectivity so it is easier to migrate away from Access, which is a poor database for a multi-user system.

    Free code: http://sol-biotech.com/code/.

    It is not that old programmers are any smarter or code better, it is just that they have made the same stupid mistake so many times that it is second nature to fix it.
    --Me, I just made it up

    The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man.
    --George Bernard Shaw

  7. #7
    Prying open my third eye.
    Join Date
    Jun 2005
    Posts
    45
    Hmm, I'm curious as well. Can you reccomend any GUI programming references for linux? I'd much rather not code in Windows. I don't mind getting down to the basics with a test editor either as I learn more that way.
    "So you're one of those condescending UNIX computer users?"

    "Here's a nickel, kid. Get yourself a better computer."

  8. #8
    Registered User mitakeet's Avatar
    Join Date
    Jun 2005
    Location
    Maryland, USA
    Posts
    212
    I have tinkered with FLTK which has a GUI builder called Fluid, but haven't done anything interesting with it. I do know that it works fine on *nix, we have it here at work. There is also wxWindows and others, but I have no familiarity with those at all. Pick one, go through the learning curve, and hope that you find an employer looking for that tookkit experience.

    Free code: http://sol-biotech.com/code/.

    It is not that old programmers are any smarter or code better, it is just that they have made the same stupid mistake so many times that it is second nature to fix it.
    --Me, I just made it up

    The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man.
    --George Bernard Shaw

  9. #9
    Registered User khpuce's Avatar
    Join Date
    May 2003
    Posts
    165
    Quote Originally Posted by mitakeet
    If you can get it, Microsoft's Visual C++ compiler is quite nice and it comes with MFC (Microsoft's Foundation Classes) that help in GUI building. MFC is more or less superceeded with .Net and there are other GUI builders for C/C++, not to mention other things entirely such as Visual Basic. DevC++ is a decent free compiler that will work fine, but has no easy GUI tools and won't compile MFC or .Net, but will compile raw Windows API GUI code. If you are serious about your application, abstract the database connectivity so it is easier to migrate away from Access, which is a poor database for a multi-user system.
    I too was thinking about Visual C++. Now I guess I'm definitely gonna try this. I am very serious about this application. That's why I want to go through the right direction from the beginning. I'll attempt to start by creating a complete standalone application with one user. So, I'm thinking of sticking with Access for the time being (as I can share/distribute my application without the need of a separate database server installation). However, if I'm successful ( ) then the next stage would be make it multiuser and network supported.

    Thanks for your help mitakeet... I really appreciate it

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. build error -- can not find operator new
    By George2 in forum C Programming
    Replies: 4
    Last Post: 11-05-2007, 02:45 PM
  2. Replies: 4
    Last Post: 02-21-2006, 06:33 PM
  3. Refreshing a Text file in GUI application?
    By solomonHk in forum C Programming
    Replies: 2
    Last Post: 01-04-2005, 03:02 PM
  4. .NET And GUI Programming :: C++
    By kuphryn in forum C++ Programming
    Replies: 4
    Last Post: 01-27-2002, 04:22 PM
  5. GUI Programming :: C++ Exclusive
    By kuphryn in forum C++ Programming
    Replies: 5
    Last Post: 01-25-2002, 03:22 PM