Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP .Net Web Controls (http://www.velocityreviews.com/forums/f63-asp-net-web-controls.html)
-   -   dynamic server control (http://www.velocityreviews.com/forums/t774640-dynamic-server-control.html)

angus 11-01-2004 03:34 AM

dynamic server control
 
Hi All,

i have an aspx form for the user to input, and those data will be stored
into the database.

I would like to build up the form dynamically by using the data in the a
database table, named question

for example, i have a question table and the data in the question table is
as follow

select * from question

---------------------------------
| question_data |
---------------------------------
| 1 + 1 = ? |
| 2 - 1 = ? |
| 2 + 2 = ? |
---------------------------------


Then, in my aspx page, the form will be as follow, (i assume that the form
is built dynamically)

(/* aspx Label here */) (/* aspx TextBox here */)

1 + 1 = ? |_____________|
2 - 1 = ? |_____________|
2 + 2 = ? |_____________|

And all the answer in the TextBox, would be saved into the database.

If i would like to add question for the form, just insert the question into
the question table

e.g.

I would like to add a question "how old are you?"

i just "insert into question (question_data) values ('how old are you?') "

Then, the aspx page will be

(/* aspx Label here */) (/* aspx TextBox here */)

1 + 1 = ? |_____________|
2 - 1 = ? |_____________|
2 + 2 = ? |_____________|
how old are you? |_____________|


So, my question is, how to build up the form dynamically like the above
example?
And what server control should i use?
And how can i pass the TextBox data to the backend codehind

Thank you.

Regards,
Angus





All times are GMT. The time now is 02:54 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.