Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

How to create a question with the option to add another line?

  • DOwen
  • DOwen's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
8 years 6 months ago #126586 by DOwen
Thanks holch, I think that sounds ideal. So perhaps the first question would be displayed on its own asking if a product needs to be added, if yes, a product type dropdown question appears, then depending on what was selected, a list of 25 questions will appear. Once completed and the Next button is pressed, a duplicated question group (with a different ID) will appear and ask the questions again.

Would this work? Not sure how I can tell the survey to display a certain question group on the next page based on conditions though?
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
8 years 6 months ago - 8 years 6 months ago #126591 by holch
You can use a relevance equation for the whole group of questions.

Let's assume that the question that defines if there will be a next question or not has the code G1add (so it is the last question of the a group of question, let's call it "G1" that contains all the information of the first product).

Then the relevance equation (not tested) should look something like that, if "yes" is code 1 and "no" any other code.
Code:
G1add=='1'

This means that the next question group will only be shown if in question G1add "Yes" was answered. If you do this with the groups for the following products (G2add, G3add), etc. they will only be shown if in the previous group of question the last question about adding another product was answered with yes.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

Last edit: 8 years 6 months ago by holch.
The following user(s) said Thank You: DOwen
The topic has been locked.
  • DOwen
  • DOwen's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
8 years 6 months ago #126601 by DOwen
Awesome thanks for this! Will try it out and let you know how I get on.

Also had a thought, I was wondering if perhaps the question type 'Multiple Short Text' would work better instead of the Array question type as this could accommodate more fields better and possibly be easier to adjust the size of the text fields...
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
8 years 6 months ago #126602 by holch
Ajusting the size of the text fields doesn't help much, I think. Because you could always make them bigger via CSS, but the limit of the field (and in the database) will still persist.

It doesn't help to have a huge test field and at the end you can only enter a few characters. If you post the 25 questions for each product, maybe we can come up with what makes sense and what not.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The topic has been locked.
  • DOwen
  • DOwen's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
8 years 6 months ago #126659 by DOwen
Thanks holch! Will report back soon.
The topic has been locked.
  • DOwen
  • DOwen's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
8 years 6 months ago #126666 by DOwen

holch wrote: Ajusting the size of the text fields doesn't help much, I think. Because you could always make them bigger via CSS, but the limit of the field (and in the database) will still persist.

It doesn't help to have a huge test field and at the end you can only enter a few characters. If you post the 25 questions for each product, maybe we can come up with what makes sense and what not.


OK either my logic is not functioning correctly or I'm making a mistake, but I can't get this to work. I can't seem to get the next quesiton group to display once 'Add ANOTHER item' is answered Yes...

Here's the survey: Click here
The topic has been locked.
  • DOwen
  • DOwen's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
8 years 6 months ago #126678 by DOwen
OK scrap that! I didn't change the answer values from '1' to whatever answer codes I had in the 'Do you want to add another item?' question. Working great now! :) Thank you!

So please take a look at the survey anyway. I've added in 25 questions, but they are all within the same question group. Perhaps I would be better displaying these actual questions on a separate page per question set? (different quesiton set per item type) As there will be around 30-50 different sets, ie 30-50 different item types. And it would probably not be sensible to have all these questions within one group...

Can I display different question groups on one page?
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
8 years 6 months ago #126683 by holch
Good that this works so far.

So please take a look at the survey anyway.


Which survey are you referring to? Can't find anything. ;-)

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The topic has been locked.
  • DOwen
  • DOwen's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
8 years 6 months ago #126684 by DOwen

holch wrote: Good that this works so far.

So please take a look at the survey anyway.


Which survey are you referring to? Can't find anything. ;-)


Sorry it was in my previous post and I had sent another straight after.

Here it is: Click here

:)
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
8 years 6 months ago #126688 by holch
OK, first of all (off topic): I really like the layout of this project. Looks very nice and professional.

Here a few comments that don't have to do with the actual problem: I wouldn't show the "this survey contains XXX questions", because actually, most people won't see that many anyway. This is really the absolute maximum. So I am not sure how much this information helps anyone.

Then for the questions "If so, desktop/documents/music/videos or all?" and "If not, do you agree any locally stored data will not be backed up?" I would show them only when "Does the new user require redirected folders for logging onto other PCs?" is marked "Yes" (set a relevance equation). Because otherwise you might get inconsistent information. E.g. "No" to the first question and then contradictory answers to the following question that don't even apply in this case. (there are a few other "if so" questions. Those I would always just show depending on the answer of the previous question like you did with question 8 and the following "if so", but actually I would get rid of "if so" then).

What is not very clear is why question 7 only shows when 6 is "no".

OK, now I made it to the end but I am not quite sure what the question is? Besides the comments above, they questionnaire seems to make sense to me.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The topic has been locked.
  • DOwen
  • DOwen's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
8 years 6 months ago #126695 by DOwen
Thank you for your reponse holch!

And thanks for the comments and compliments, appreciate it! :)

I will remove the 'this survey contains XXX questions', as I agree its of no use.

Thanks for the heads up on the questions, will look into this. Not sure whu question 7 only shows when 6 is No at your side, because they both display here? Strange.

It's worth bearing in mind that these questions are subject to change, and the question types will most definitely change. I was given the questions from another department, but they'll need to be re-worded.

What needs to happen next is I will need to create 30-50 sets of questions, similar to what I've shown in the survey, all with roughly 5-25 questions inside them. They will vary depending on the item type selected in the dropdown. ie, depending on what item is selected in the dropdown, a different set of questions will appear underneath.

This is going to be laborious but I would say that adding these question lists to the same question group is not going to be very organised and going to make things very difficult for myself. There would be hundreds of questions in one question group!

So I thought perhaps it would be better to keep each set of questions in a question group. However I'm assuming this means a different page per question group, and I'm also assuming this would mean the initial dropdown question would be on a separate previous page? So would it be possible to display a question group within the same page? ie when I select a certain item type inside the dropdown, the relevant question group appears underneath. Can this be done?
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
8 years 6 months ago #126700 by holch
Unfortunately the concept of "page" doesn't exist in Limesurvey.

You have 3 options:
- Survey all in one (not going to recommend this for you... ;-) )
- Question by question (not going to recommend this for you either)
- So you just have the group by group option. So you need the question groups to create some kind of "page" concept, as you are doing right now. There is no way to display more than 1 group on a page (except for all in one, where all groups are on one page). So that doesn't really help you much.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose