?
Solved

Good placeholder example for database driven questionnaire

Posted on 2010-11-12
3
Medium Priority
?
791 Views
Last Modified: 2013-12-17
Does anyone know where I can find a good placeholder tutorial/project example?

I want to store a questionnaire in a database table, defining whether to use a radio, text field, combobox, etc., then loop through the table, building my form and displaying it on the page. Then retrieve the data from the form fields, and store back in the table.

Using VS2010, 4.0 framework. C# or VB.NET is fine.

Thanks!
0
Comment
Question by:Starr Duskk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 5

Assisted Solution

by:JayFromPep
JayFromPep earned 2000 total points
ID: 34121228
I would use a repeater.

Each question would be a record in a table of possible questions.  Based on your query, you populate the repeater with information retrieved.

On submit, grab the value from the fields and put it back into the database.
0
 
LVL 2

Accepted Solution

by:
Starr Duskk earned 0 total points
ID: 34122885
A repeater template must repeat the same type of object: text field, radio button or combobox, etc.

Row one might be a text field and a combobox, row two might be a radio button, row three might be a text field only, and so on.

I don't think a repeater will allow that. I do know a placeholder will.

I found these snippets of code:
http://www.beansoftware.com/ASP.NET-Tutorials/Dynamic-User-Interface.aspx
 
http://www.4guysfromrolla.com/articles/081402-1.aspx
 
http://www.denisbauer.com/ASPNETControls/DynamicControlsPlaceholder.aspx
 
http://www.startvbdotnet.com/aspsite/controls/panel.aspx
 
http://www.w3schools.com/aspnet/control_placeholder.asp


And for repeaters, I found this one on creating a repeater template programmatically:
http://msdn.microsoft.com/en-us/library/Aa289501

0
 
LVL 2

Author Closing Comment

by:Starr Duskk
ID: 34276788
mine answers the question
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question