| | |
its a challenge... but i am stuck!!!
Please support our ASP.NET advertiser: $4.95 a Month - ASP.NET Web Hosting – Click Here!
![]() |
•
•
Join Date: Jun 2006
Posts: 22
Reputation:
Solved Threads: 0
hi all
now this is something hard and i hope that someone knows how to do it
lets say that i have a table in the database named "Test"
the table contains this data
Question_____________________Type
What is your name? ________________Txt
How are you?______________________Rad
the webform has only a Button named "Build" for example and a Grid View
the task is:
At runtime when you press the button "Build" the application do 3 things:
1- fill the first column of Grid View with the Questions from the table
this is easy to do
but the second and third are somehow complicated
2- whereever the Type in the tabel "Test" is "Txt" the application create a TextBox control and place it in the second column of the Grid View next to the question that has a Txt type
3- whereever the type is "Rad" the application create a RadioButtion control and place it in the second column of the Grid View next to the question that has a Rad type
does anyone know how to do it?
now this is something hard and i hope that someone knows how to do it
lets say that i have a table in the database named "Test"
the table contains this data
Question_____________________Type
What is your name? ________________Txt
How are you?______________________Rad
the webform has only a Button named "Build" for example and a Grid View
the task is:
At runtime when you press the button "Build" the application do 3 things:
1- fill the first column of Grid View with the Questions from the table
this is easy to do
but the second and third are somehow complicated
2- whereever the Type in the tabel "Test" is "Txt" the application create a TextBox control and place it in the second column of the Grid View next to the question that has a Txt type
3- whereever the type is "Rad" the application create a RadioButtion control and place it in the second column of the Grid View next to the question that has a Rad type
does anyone know how to do it?
Last edited by infinity4ever; Jul 1st, 2006 at 3:36 am. Reason: Layout is not good
Patience!
Also, we are not here to do your work for you, the general edicate here is to state the question / problem and provide the work you have tried to to solve it but have been unsuccessful.
Saying that here is some sample code that may help you at least get started.
1. Hopefully you know you will require some logic statements (if/then/else or while, etc) to solve this.
2. Example of adding controls at runtime
Hope this helps
Also, we are not here to do your work for you, the general edicate here is to state the question / problem and provide the work you have tried to to solve it but have been unsuccessful.
Saying that here is some sample code that may help you at least get started.
1. Hopefully you know you will require some logic statements (if/then/else or while, etc) to solve this.
2. Example of adding controls at runtime
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load 'Put user code to initialize the page here Dim objTB As TextBox objTB.ID = "tbOne" objTB.Text = "Hello There" Page.Controls.Add(objTB) End Sub
Hope this helps
![]() |
Similar Threads
- java.util.zip help (please) (Java)
- Anyone mind helping out a stuck noob? (Java)
- Windows XP is stuck! (Windows NT / 2000 / XP)
- Stuck on start up (Windows NT / 2000 / XP)
- Internet explorer 5 gets stuck (Web Browsers)
- stuck in lower case, lost functions (Windows NT / 2000 / XP)
- Solving Challenge Suggestion (DaniWeb Community Feedback)
- [Member of the Month - Feb '04] Popular Thread challenge! (Geeks' Lounge)
- Tutorials for Linux (*nix Software)
Other Threads in the ASP.NET Forum
- Previous Thread: Dropdown list Last value
- Next Thread: Atlas - Ajax
| Thread Tools | Search this Thread |
.net 2.0 3.5 activexcontrol advice ajax alltypeofvideos asp asp.net bc30451 beginner bottomasp.net browser businesslogiclayer c# cac checkbox class commonfunctions compatible content contenttype countryselector courier css dataaccesslayer database datagrid datagridview datagridviewcheckbox datalist deployment development dgv dropdownlist dropdownmenu dynamic dynamically edit embeddingactivexcontrol fileuploader fill findcontrol flash flv formatdecimal formview gridview gudi iframe iis javascript listbox menu microsoft mouse mssql multistepregistration nameisnotdeclared news opera panelmasterpagebuttoncontrols problem redirect registration relationaldatabases reportemail schoolproject security serializesmo.table sessionvariables silverlight smartcard smoobjects software sql sql-server sqlserver2005 ssl textbox tracking treeview unauthorized validatedate validation vb.net video videos virtualdirectory vista visual-studio visualstudio web webapplications webarchitecture webdevelopemnt webdevelopment webprogramming webservice youareanotmemberofthedebuggerusers






