Creating a scrollable window for runtime created controls

Discussion in 'C++' started by dfreas@gmail.com, Nov 6, 2005.

  1. Guest

    I'm using Bloodshed Dev-C++ to write a program used to calculate orders
    for my business. Until recently a command line program has been
    sufficient but it is beginning to become cumbersome so I've switched to
    writing a windows program and am learning the API as I go. If I use a
    term wrong correct me - my experience in windows programming is
    limited, I do however understand C++ fairly well as I've been using it
    for about four years.

    I want to be able to add controls at runtime to my main window - which
    I have succesfully done. The number of controls is dependant on the
    customer's order size. For small orders the program works fine. The
    problem is for larger orders where the EDIT controls extend far beyond
    the bottom of the window. I need to make the window scrollable.

    Adding "WS_VSCROLL | WS_HSCROLL" did not work. It provided the window
    with scrollbars but when the EDIT controls extend beyond the bottom of
    the window I still cannot scroll down to see them.

    Please let me know what I'm doing wrong and how to fix it. I assume I'm
    leaving out an important step.

    Thanks
    -Daniel
    , Nov 6, 2005
    #1
    1. Advertising

  2. John McCabe Guest

    wrote:

    >I'm using Bloodshed Dev-C++ to write a program used to calculate orders
    >for my business. Until recently a command line program has been
    >sufficient but it is beginning to become cumbersome so I've switched to
    >writing a windows program and am learning the API as I go. If I use a
    >term wrong correct me - my experience in windows programming is
    >limited, I do however understand C++ fairly well as I've been using it
    >for about four years.
    >
    >I want to be able to add controls at runtime to my main window - which
    >I have succesfully done. The number of controls is dependant on the
    >customer's order size. For small orders the program works fine. The
    >problem is for larger orders where the EDIT controls extend far beyond
    >the bottom of the window. I need to make the window scrollable.


    I don't know anything about Bloodshed Dev-C++, but can't you use
    something like a list control (CListCtrl in MFC)?
    John McCabe, Nov 7, 2005
    #2
    1. Advertising

  3. wrote:
    > I want to be able to add controls at runtime to my main window - which
    > I have succesfully done. The number of controls is dependant on the
    > customer's order size. For small orders the program works fine. The
    > problem is for larger orders where the EDIT controls extend far beyond
    > the bottom of the window. I need to make the window scrollable.


    There are many controls that provide this capabiity. See the Grid
    Controls section here...
    http://www.codeguru.com/Cpp/controls/controls/

    --
    Scott McPhillips [VC++ MVP]
    Scott McPhillips [MVP], Nov 7, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. RJN
    Replies:
    1
    Views:
    919
    =?Utf-8?B?S2FtYWwgVC4=?=
    Oct 26, 2004
  2. Lenny
    Replies:
    9
    Views:
    506
  3. Nathan Sokalski

    Creating a Scrollable Multi-Column List

    Nathan Sokalski, Aug 16, 2007, in forum: ASP .Net
    Replies:
    3
    Views:
    442
    =?Utf-8?B?TGFkaXNsYXYgTXJua2E=?=
    Aug 17, 2007
  4. Nathan Sokalski

    Creating a Scrollable Multi-Column List

    Nathan Sokalski, Aug 16, 2007, in forum: ASP .Net Web Controls
    Replies:
    2
    Views:
    199
    Ladislav Mrnka
    Aug 17, 2007
  5. Replies:
    1
    Views:
    94
    Thomas 'PointedEars' Lahn
    Dec 8, 2005
Loading...

Share This Page