Thread: gui for win32 c++ programming

  1. #1
    Registered User
    Join Date
    Nov 2008
    Posts
    222

    Thumbs up gui for win32 c++ programming

    hi all

    i am new to win32 gui programming for c++. the image is attached here which needs to be developed using c++ win32 api.

    any resources or source code or samples will be helpful. anyone suggest me some links?

  2. #2
    Registered User
    Join Date
    Nov 2008
    Posts
    222
    am using visual studio 2005. what is the procedure to create a win32 project?do i need to create windows application or console application?is it empty project?

  3. #3
    Registered User
    Join Date
    Nov 2008
    Posts
    222
    i need to know how to programme a group radio button?how to add mutilple IDS to .rc file?do i need to create a dialog windows and then add these controls?pls clarify me soon.

  4. #4
    Registered User
    Join Date
    Nov 2008
    Posts
    222
    can anyone help me?its urgent

  5. #5
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446
    Look, you are asking someone to teach you how to make a full windows program without you ever having learned anything about C++ programming and the Windows API. It's just not going to happen.
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  6. #6
    Registered User
    Join Date
    Nov 2008
    Posts
    222
    i am a c++ programmer,but am new to win32 apis, hence need some help. if you are good in win32, why don't you share your ideas?

  7. #7
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Creating a GUI is a science. You need to ask more specific questions.
    The basics of creating a GUI depends on what library you want to use. For example, there is pure Win32, there is MFC and wxWidgets, etc.
    For pure win32, create a Windows application (not windows form). Then you can go to the resource view, and add a dialog. In there, you can add controls to the form. But that's it for the graphical. Then you need to do it, and that's where the problems begin.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  8. #8

  9. #9
    Registered User
    Join Date
    Nov 2008
    Posts
    222
    I cannot use MFC anymore since the target device supports only WIN32 api, hence everything n eds to be developed from the scratch. i have visual studio 2005, hence developing win32 applications using c++. any help would be appreciated as am new to win32 api programming, eventhough am a c++ programmer. i need samples in win32 for GUI development, that would work with VS 2005. anyone please help me?

  10. #10
    Registered User
    Join Date
    Nov 2008
    Posts
    222
    1)how to program group radio button using win32 apis?which are the event handlers to be called?any samples are available?
    2)how to create a button and load image to it using win32 api?
    3)how to create a list control and add columns to it as shown in the image using win32 apis?
    4)

  11. #11
    Registered User
    Join Date
    Nov 2008
    Posts
    222
    4) how do i create a combo box and check box as shown in images using win32 c++ apis?what are the events being handled?

  12. #12
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    There is something called the edit button. Use it.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  13. #13
    train spotter
    Join Date
    Aug 2001
    Location
    near a computer
    Posts
    3,868
    I will answer your questions but that will not help you too much...

    1. You can use MSVCs resource editor to create radio buttons on a dialog or create them on the fly using CreateWindow(). Respond to BN_CLICKED msgs in the dialogs callback. Plenty of samples here and on MSDN.

    2. Use the resource editor or CreateWindow(). MFC has a class called CBitmapButton. Otherwise, depending on the image you want on the button, you will have to give the button the owener draw style and handle WM_DRAWITEM msgs for it (and GDI creating and clean up).

    3. Use the resource editor or CreateWindow(). Add the LVS_REPORT style. You will need to insert the columns and rows on the fly.

    4. Use the resource editor or CreateWindow(). You will have to add the items on the fly and if required allow the user to add items. Combos need to use at least the CBN_SELCHANGE mgs.

    Quote Originally Posted by leo2008 View Post
    I cannot use MFC anymore since the target device supports only WIN32 api, hence everything n eds to be developed from the scratch. i have visual studio 2005, hence developing win32 applications using c++.
    What is the target XPe, CE or another MS OS? [I use MFC on all these.]

    You can use static linking (build time) of the MFC DLLs to your app (rather than the default dynamic linking (runtime)). This will allow it to be used on any machine running WIN32.

    MFC is much easier to create a stable app than pure WIN32.

    What you want done is somewhat complex requiring GDI, including double buffering, mem DCs and modifing the raw image data. It will not be an easy project for a novice.
    "Man alone suffers so excruciatingly in the world that he was compelled to invent laughter."
    Friedrich Nietzsche

    "I spent a lot of my money on booze, birds and fast cars......the rest I squandered."
    George Best

    "If you are going through hell....keep going."
    Winston Churchill

  14. #14
    Registered User
    Join Date
    Nov 2008
    Posts
    222
    Target in Win XP Pro. I understand by using MFC we can easily create, but i need to use WIN32 API only, since target device doesnt support MFC. It will be of great help if you could give me some WIN32 C++ code snippets for edit button, combo box,radio button,list control,push button etc.

  15. #15
    Registered User
    Join Date
    Nov 2008
    Posts
    222
    what is the win32 c++ api to create checkbox?also how can i do group radio button programming in win32 c++??any source code would be helpful to understand the apis.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. any shareware GUI to use for Windows ?
    By Amy N. in forum C Programming
    Replies: 6
    Last Post: 07-22-2009, 01:31 PM
  2. .NET And GUI Programming :: C++
    By kuphryn in forum C++ Programming
    Replies: 4
    Last Post: 01-27-2002, 04:22 PM
  3. GUI Programming :: C++ Exclusive
    By kuphryn in forum C++ Programming
    Replies: 5
    Last Post: 01-25-2002, 03:22 PM
  4. C++: Reference Book, GUI, Networking & Beyond
    By kuphryn in forum C++ Programming
    Replies: 4
    Last Post: 11-10-2001, 08:03 PM
  5. GUI (Graphical User Interface) Help Needed
    By Unregistered in forum C++ Programming
    Replies: 1
    Last Post: 10-11-2001, 10:35 AM