List Info

Thread: C-Sharp (C#) Group: Dynamic component creation...?




C-Sharp (C#) Group: Dynamic component creation...?
user name
2006-01-24 16:01:45
I'm still very new to C#, but I'm starting to get the hang
of it. My
experience with C and C++ has helped.

I'm going to attempt to write an application to generate a
multiple
choice test (A quiz generator for WebCT), but before I do
this, I'd
like to plan first and find out a few things.

Since each multiple choice question can have a different
number of
answers (one question could have three possible answers,
another could
have ten or more), how do I go about making the number of
answers
dynamic, i.e. the number of textboxes needed (one per
answer) is not
known beforehand.

Also, I'd like to have each answer textbox preceded by a
checkbox
(and/or radio button) to denote which is the correct answer,
so if
there are five possible answers, there should be five
textboxes each
with a checkbox/radio button in front.

I don't know of any other way of doing this except to make
arrays of
components and hide/show them at the appropriate time, but
my instinct
tells me that Microsoft forsaw this need and there has to be
some sort
of component (or piece of code) that does this task more
simply. After
all, it's something that would be re-used quite often in
different
apps.

Any help at all would be appreciated.

Sincerely,

Gordon E.

C-Sharp (C#) Group: Re: Dynamic component creation...?
user name
2006-01-30 23:15:42
OK, since no one seems to want to answer my question, could
someone at
least point me toward some documentation? Or maybe a
tutorial?

If not that, at least point me toward something that
explains custom
control creation for Windows Forms.

Sincerely,

Gordon E.

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )