its a challenge... but i am stuck!!!

Please support our ASP.NET advertiser: $4.95 a Month - ASP.NET Web Hosting – Click Here!
Reply

Join Date: Jun 2006
Posts: 22
Reputation: infinity4ever is an unknown quantity at this point 
Solved Threads: 0
infinity4ever infinity4ever is offline Offline
Newbie Poster

its a challenge... but i am stuck!!!

 
0
  #1
Jul 1st, 2006
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?
Last edited by infinity4ever; Jul 1st, 2006 at 3:36 am. Reason: Layout is not good
Reply With Quote Quick reply to this message  
Join Date: Jun 2006
Posts: 22
Reputation: infinity4ever is an unknown quantity at this point 
Solved Threads: 0
infinity4ever infinity4ever is offline Offline
Newbie Poster

Re: its a challenge... but i am stuck!!!

 
0
  #2
Jul 2nd, 2006
huh??!!!!! no one knows??? could it be?????
Reply With Quote Quick reply to this message  
Join Date: Feb 2003
Posts: 793
Reputation: Paladine has a spectacular aura about Paladine has a spectacular aura about Paladine has a spectacular aura about 
Solved Threads: 26
Team Colleague
Paladine's Avatar
Paladine Paladine is offline Offline
Master Poster

Re: its a challenge... but i am stuck!!!

 
0
  #3
Jul 2nd, 2006
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

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
Assistant Manager, Pharmacy Informatics
Wordpress Learning Blog
Updated : ASP.Net Login Code
Reply With Quote Quick reply to this message  
Join Date: Jun 2006
Posts: 22
Reputation: infinity4ever is an unknown quantity at this point 
Solved Threads: 0
infinity4ever infinity4ever is offline Offline
Newbie Poster

Re: its a challenge... but i am stuck!!!

 
0
  #4
Jul 3rd, 2006
hi paladine

you are mistaken its not that i want u to do my work

i know how to add the control at runtime

the main point here is how to load the control in the second column of the grid view?

this is the thing i tryed and failed in

this is the question
Reply With Quote Quick reply to this message  
Join Date: Jun 2006
Posts: 22
Reputation: infinity4ever is an unknown quantity at this point 
Solved Threads: 0
infinity4ever infinity4ever is offline Offline
Newbie Poster

Re: its a challenge... but i am stuck!!!

 
0
  #5
Jul 8th, 2006
anyone knows how to do it?
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the ASP.NET Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC