Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Multiple instances of edit control needed

johnny_XPjohnny_XP Member Posts: 7
Hello to all. This is a simple question. I'm creating a dialog box in MFC. I need 6 different edit control in the dialog, one of which needs validation. The validation is the same for all: the provided input must be a positive number between 0 and 20. Which one you think is best practice:
a) 6 instances of the edit control class dynamic created and attached to the dialog?
b) drag 6 edit controls from the toolbox?
c) May be something else?
In the case of a) how can achieve that? Is a good idea to create an array of edit controls?

Thanks in advance.

Comments

  • AsmGuru62AsmGuru62 Member Posts: 6,519
    : Hello to all. This is a simple question. I'm creating a dialog box
    : in MFC. I need 6 different edit control in the dialog, one of which
    : needs validation. The validation is the same for all: the provided
    : input must be a positive number between 0 and 20. Which one you
    : think is best practice:
    : a) 6 instances of the edit control class dynamic created and
    : attached to the dialog?
    : b) drag 6 edit controls from the toolbox?
    : c) May be something else?
    : In the case of a) how can achieve that? Is a good idea to create an
    : array of edit controls?
    :
    : Thanks in advance.
    [blue]b) is easiest way, IMHO.
    [/blue]
Sign In or Register to comment.