Creating a new Question Type

Sep 16, 2010 at 7:58 PM

Hi Omu,

Can you guide me a bit as to how I might implement a new question type? Specifically I want to implement a slider to indicate 0%-100% (don't worry about the javascript part, I got that covered). I'm wondering what would be the steps to adding this one and other question types. 

Thanks for your generosity with this project!

--Aaron

Coordinator
Sep 17, 2010 at 6:19 AM
Edited Sep 17, 2010 at 8:08 AM

Hi,

* you add a new item to the ControlType Enum

* add this in the sql script: insert into QuestionTypes values(7, 'slider')

 

* implement the IHtmlGenerator for your new question type and add it in the HtmlGeneratorFactory

* implement the IValueReader and add in the ValueReaderFactory

* Party !!!

Cheerz ;)

May 3, 2011 at 4:29 AM

Hi Omu,

Is there a way to implement the dropdownlist as a new question type? I even couldn't figure out the way to deal with database for this issue.

Thanks in advance.

dyn

Coordinator
May 3, 2011 at 6:42 AM

there has been a long time since I've been doing something with this project, as I remember I had factories where I was registering implementations for each type of something