MFC group box question

  • Thread starter Thread starter Bruno van Dooren
  • Start date Start date
B

Bruno van Dooren

Hi,

i am working on a small MFC dialog based application.
a number of controls belongs together and i want to enable / disable them
together.

i thought i'd use a group box, just as you'd do in a C# application, but i
just can't find any way
to use the group box as anything other than a decoration.

do i have to do everything manually? i have tried selecting everything and
then setting the group property to true, but that didn't seem to do
anything.

kind regards,
Bruno.
 
i am working on a small MFC dialog based application.
a number of controls belongs together and i want to enable / disable them
together.

i thought i'd use a group box, just as you'd do in a C# application, but i
just can't find any way
to use the group box as anything other than a decoration.

Bruno,

That's normal in an MFC/SDK application. You can do it by re-parenting
each control (use SetParent) to have the group box as its parent, but
doing so can give rise to some quirks (I can't remember exactly what
they were, other than there were some), so I wouldn't recommend doing
it. Where I have such situations, I usually write code to
enable/disable a set of control IDs in an array.

Dave
 
Back
Top