Hi all,
I have to design a quiz page which includes up to 200 questions. What users
do is they start the quiz, go to page1 with question1, enter some answers,
click next to go page2 with question2, and so on until they get to page100
then they will hit submit button to submit their answers.
My approach right now is: In one web form only,
- load all 200 questions (or depending on the requirement, could be 20 or
200 questions, ie the number of questions varies) into a dataset,
- then depends on the dataset size, dynamically create the same number of
panel controls to contain the questions and the textboxes for the answers,
- add the panel controls to the web form.
- then depends on the which question the user is at, I'll show the
corresponding panel and hide the other panels.
That way I can retain all user answers in one page.
However, since the page is so big ( could grow up to 200 panels), I'm not
sure this is a good approach.
My question, is it ok with this approach performance wise. Any idea of how
to do it. Thanks in advance. 10 1316
Hmm...why are you requiring users to stay on the same page? For user
experience, or programming convenience?
You could instead show only one question on the page, have the user click
"Next" (which would be a submit button), then in your codebehind use
sessions and view state to store their answers thus far, determine the next
question to show, and when they're done, store all the information into a
database (or whatever).
IMO you should only do what you're doing if there's a reason why users
shouldn't refresh the page...maybe your users don't mind the initial wait
but hate page reloads.
--
Ben Strackany www.developmentnow.com
<a href="http://www.development now.com">dn</a>
"hn" <hn@discussions .microsoft.com> wrote in message
news:44******** *************** ***********@mic rosoft.com... Hi all,
I have to design a quiz page which includes up to 200 questions. What
users do is they start the quiz, go to page1 with question1, enter some answers, click next to go page2 with question2, and so on until they get to page100 then they will hit submit button to submit their answers.
My approach right now is: In one web form only,
- load all 200 questions (or depending on the requirement, could be 20 or 200 questions, ie the number of questions varies) into a dataset,
- then depends on the dataset size, dynamically create the same number of panel controls to contain the questions and the textboxes for the answers,
- add the panel controls to the web form.
- then depends on the which question the user is at, I'll show the corresponding panel and hide the other panels.
That way I can retain all user answers in one page.
However, since the page is so big ( could grow up to 200 panels), I'm not sure this is a good approach.
My question, is it ok with this approach performance wise. Any idea of how to do it. Thanks in advance.
From a user point for view, I seriously wonder how many users will answer
200 questions!
"Ben Strackany" <in********@dev elopmentnow.nos pam.com> wrote in message
news:%2******** ********@TK2MSF TNGP14.phx.gbl. .. Hmm...why are you requiring users to stay on the same page? For user experience, or programming convenience?
You could instead show only one question on the page, have the user click "Next" (which would be a submit button), then in your codebehind use sessions and view state to store their answers thus far, determine the
next question to show, and when they're done, store all the information into a database (or whatever).
IMO you should only do what you're doing if there's a reason why users shouldn't refresh the page...maybe your users don't mind the initial wait but hate page reloads.
-- Ben Strackany www.developmentnow.com
<a href="http://www.development now.com">dn</a>
"hn" <hn@discussions .microsoft.com> wrote in message news:44******** *************** ***********@mic rosoft.com... Hi all,
I have to design a quiz page which includes up to 200 questions. What users do is they start the quiz, go to page1 with question1, enter some
answers, click next to go page2 with question2, and so on until they get to
page100 then they will hit submit button to submit their answers.
My approach right now is: In one web form only,
- load all 200 questions (or depending on the requirement, could be 20
or 200 questions, ie the number of questions varies) into a dataset,
- then depends on the dataset size, dynamically create the same number
of panel controls to contain the questions and the textboxes for the
answers, - add the panel controls to the web form.
- then depends on the which question the user is at, I'll show the corresponding panel and hide the other panels.
That way I can retain all user answers in one page.
However, since the page is so big ( could grow up to 200 panels), I'm
not sure this is a good approach.
My question, is it ok with this approach performance wise. Any idea of
how to do it. Thanks in advance.
Hi Ben,
Everything is in the same page because of programming convenience only.
Since the number of questions varies, so I want to to create the pages
dynamically depending on the number of questions. I don't want to create 200
pages ahead. But yeah, I know it's not good that way.
"Ben Strackany" wrote: Hmm...why are you requiring users to stay on the same page? For user experience, or programming convenience?
You could instead show only one question on the page, have the user click "Next" (which would be a submit button), then in your codebehind use sessions and view state to store their answers thus far, determine the next question to show, and when they're done, store all the information into a database (or whatever).
IMO you should only do what you're doing if there's a reason why users shouldn't refresh the page...maybe your users don't mind the initial wait but hate page reloads.
-- Ben Strackany www.developmentnow.com
<a href="http://www.development now.com">dn</a>
"hn" <hn@discussions .microsoft.com> wrote in message news:44******** *************** ***********@mic rosoft.com... Hi all,
I have to design a quiz page which includes up to 200 questions. What users do is they start the quiz, go to page1 with question1, enter some answers, click next to go page2 with question2, and so on until they get to page100 then they will hit submit button to submit their answers.
My approach right now is: In one web form only,
- load all 200 questions (or depending on the requirement, could be 20 or 200 questions, ie the number of questions varies) into a dataset,
- then depends on the dataset size, dynamically create the same number of panel controls to contain the questions and the textboxes for the answers,
- add the panel controls to the web form.
- then depends on the which question the user is at, I'll show the corresponding panel and hide the other panels.
That way I can retain all user answers in one page.
However, since the page is so big ( could grow up to 200 panels), I'm not sure this is a good approach.
My question, is it ok with this approach performance wise. Any idea of how to do it. Thanks in advance.
well, unfortunately, that's the requirement.
"John" wrote: From a user point for view, I seriously wonder how many users will answer 200 questions!
"Ben Strackany" <in********@dev elopmentnow.nos pam.com> wrote in message news:%2******** ********@TK2MSF TNGP14.phx.gbl. .. Hmm...why are you requiring users to stay on the same page? For user experience, or programming convenience?
You could instead show only one question on the page, have the user click "Next" (which would be a submit button), then in your codebehind use sessions and view state to store their answers thus far, determine the next question to show, and when they're done, store all the information into a database (or whatever).
IMO you should only do what you're doing if there's a reason why users shouldn't refresh the page...maybe your users don't mind the initial wait but hate page reloads.
-- Ben Strackany www.developmentnow.com
<a href="http://www.development now.com">dn</a>
"hn" <hn@discussions .microsoft.com> wrote in message news:44******** *************** ***********@mic rosoft.com... Hi all,
I have to design a quiz page which includes up to 200 questions. What users do is they start the quiz, go to page1 with question1, enter some answers, click next to go page2 with question2, and so on until they get to page100 then they will hit submit button to submit their answers.
My approach right now is: In one web form only,
- load all 200 questions (or depending on the requirement, could be 20 or 200 questions, ie the number of questions varies) into a dataset,
- then depends on the dataset size, dynamically create the same number of panel controls to contain the questions and the textboxes for the answers, - add the panel controls to the web form.
- then depends on the which question the user is at, I'll show the corresponding panel and hide the other panels.
That way I can retain all user answers in one page.
However, since the page is so big ( could grow up to 200 panels), I'm not sure this is a good approach.
My question, is it ok with this approach performance wise. Any idea of how to do it. Thanks in advance.
On the same page because of convenience?
So you could display only one question at a time, you just dont want to
create 200 pages. right?
Why not just load the questions dynamically from a database? It would
look like 200 pages, but really you are only using 1 with 200 question
loaded individually. Then the page loads wont be so bad, and you dont
need setup 200 pages.
Greg http://www.1stbyte.com
So a dataset of 200 questions should be ok? Thanks for the advice, Greg.
"Greg Fischer" wrote: On the same page because of convenience?
So you could display only one question at a time, you just dont want to create 200 pages. right?
Why not just load the questions dynamically from a database? It would look like 200 pages, but really you are only using 1 with 200 question loaded individually. Then the page loads wont be so bad, and you dont need setup 200 pages.
Greg http://www.1stbyte.com
No it wouldn't be a dataset of 200 questions. It would be a dataset or
maybe a datareader of 1 question. You will hold the questions in a
database and draw from them based on what your user selects in the web
form interface or in your app logic, or both I guess.
You want to save your test answers, right? So you will need to have a
database to save them in, whether it be a text file or spreadsheet or
Access or SQL Server. Since using a text file or spreadsheet sounds
pretty limiting for what you want, just use an Access db. And since you
are using a db anyway, just save all your questions there instead of on
one BIG page.
I would bet you will want to have a few pages to make that app, but
certainly not 200.
Why does the # of questions vary? Different tests? (so diff amount of ?'s)
I hope this helps.
Greg http://www.1stbyte.com
I've done exactly what you are doing. What I did is create different pages
for different predefined question types (essays, something involving
calendars, multiple choice, etc...) Then what I did was stored each response
in the database, look for the maximum last question and assume that's the
question they were on. There was more to it than that and it worked great
(10,000 successful uses in a 3 month period.) So basically read only one
question at a time and it really won't matter if it's 10 or 10,000 questions. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Todd Steury |
last post by:
Greetings Python'ers:
I'm just an amature who occasionally uses Python for complex mathematical
models. The current model I'm working with occasionally generates really
large numbers that are either "float" or "complex" types. These numbers are
so large that I either get an overflow error, or some funky code like #INF
or 1.#INDj. However I...
|
by: Greg |
last post by:
I am working on a project that will have about 500,000 records in an XML
document. This document will need to be queried with XPath, and records
will need to be updated. I was thinking about splitting up the XML into
several XML documents (perhaps 50,000 per document) to be more efficient but
this will make things a lot more complex because...
|
by: Molly |
last post by:
Does anyone know of any good tools for fast, on-line reorgs of a very
large DB2 UDB table?
We need to reorg a couple of our large (+1 billion rows) tables. We
migrated from V7.2 to V8.1, but we still have type-1 indexes defined on
our tables, and cannot take advantage of the new Online Reorg utility
in V8. We could drop and recreate our...
|
by: Ramin Dalkouhi |
last post by:
Hello,
We are currently working on a serialization task which imports data
into memory streams. At first, we had problems with a very high amount
of data as the memory management of such memory streams is always
multiplying the required memory buffer size by two. We are now
"guessing" the required amount and are setting the capacity...
|
by: Steve |
last post by:
Sorry in advance for my ignorance. Any help would sure be
appreciated. I'm writing a fairly simple application with VB.Net and
am obviously a bit of a newbie. This application will be used by 1, 2
or at most 3 people concurrently and I'm using Access 2003 for my data
source. We are not dealing with a large amount of data (5 or 6
tables,...
| |
by: lgbjr |
last post by:
Hi All,
I need some advice. I have a table in MSDE2000 with about 3 million records.
It's a city database. What I want to do is have 3 comboboxes on a form. The
first would be to select a country, second, to select a region (state,
province, etc) in that country, and the third would be a list of cities in
the selected region.
I don't...
|
by: Elliot Rodriguez |
last post by:
WinXP Pro
Let me preface this by saying I have developed with the .NET IDE since its
release, and I consider myself reasonably savvy with it.
I have a medium sized form with about 120 controls - 60 labels and the rest
are DropDownLists and TextBoxes. Almost every TextBox or DropDownList is
placed in a Panel control whos visibility...
|
by: Peter Duniho |
last post by:
This is kind of a question about C# and kind of one about the framework.
Hopefully, there's an answer in there somewhere. :)
I'm curious about the status of 32-bit vs 64-bit in C# and the framework
classes. The specific example I'm running into is with respect to byte
arrays and the BitConverter class. In C# you can create arrays larger...
|
by: robert |
last post by:
I'm very pleased to announce that Foundations of F#, the first book to
be published on the F# programming, will finish its first printing
run, tomorrow, Friday 25th May. It should reach any pre-order
customers between 5 to 10 days later, meaning if ordered it on Amazon
or Borders (or any other online store), it should be with you before
the...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it. ...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |