Explore the community Forums Lectora Lectora Questions & Answers Drop List Killing Me….(Solved!)

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #375085 Score: 0
    Profile photo of Andy Krayenhagen
    Andy Krayenhagen
    Member
    beginner
    intermediate
    advanced
    picture perfect
    profile
    friend finder
    curious george
    wise owl
    contributor
    2 pts
    @akrayenhagen9721

    OK Ladies and Gents,

    First, apparently I have issues posting to this board (forgive me, I’m new to this site), and my messages aren’t coming through correctly. Next thank you to MATH for trying to assist me with my drop list efforts, however, your fix wouldn’t work for what I was attempting to do (but I did figure it out). As many of you (being course designers) have probably experienced with training the trainers, we have to teach our soldiers (in charge of enrollments to courses) how to enroll students an ensure that certain guidelines are followed. Well this is no different. Here was my dilema:

    1) I had to recreate a web page with a drop list, that when each selection was made, a set of text would pop up next to it….. Easy right? NOPE!

    2) The text had to be formatted word for word what was in the original drop list…. This created some issues (Please see the attachments (If they come through)).

    The drop list had multiple items with similar attributes so creating a function that ran that said, “If this (EXACT) text pops up show this text in the text box on the right of the drop list.  I tried to be crafty and make a text box that the text would change every time a  different selection was made. This failed miserably! I found small errors like extra spaced at the end that kept it from functioning, wording was to similar so two text boxes overwrote itself, the text box wouldn’t fill at all, etc. So I found that using the Condition Relationship “Equal To” doesn’t mean EXACTLY to, having Spaces at the end of the Value would keep it from functioning, Using the Relationship Condition of “Contains” means that if you use this and anything else in the drop list had a similar wording it wouldn’t function correctly.

    All this being said, we got crafty and used some “Equal To” and some “Contains” and checked each line to ensure NO extra spaces were present. We also figured out that we would have to do this in Action Groups and that no matter what, we’d have to run an Action Group to HIDE everything first every though it was set to be initially hidden.

    I wanted to share this with everyone so they won’t have the same issues.

     

    Andy

    #375089 Score: 0
    Profile photo of Stan Miller
    Stan Miller
    Member
    beginner
    intermediate
    LUC16 Attendee
    wise owl
    contributor
    curious george
    friend finder
    LUC17 Attendee
    35 pts
    @smiller7502

    I want to clarify something: “Equal to” does mean EXACTLY equal to. A string of characters with a space at the end is not the same as that same string of characters without a space at the end, and should not be treated as such.

    Also, I’m sorry I didn’t see your original post, because there would have been a more reliable way to go about this than combining some “equal to” and some “contains” conditions. I try never to quibble with code that works, but I do fear that your solution will be very difficult to edit six months from now when you’ve done 300 other things and then have to come back to this because you have to add a new item to the list.

    With JavaScript you can read an external list at run time to populate a drop-down list in your course. Doing that automatically numbers the list, so you can refer to the selected item by its number. Or maybe even better in this case, the same external list could contain both the options for your drop-down list and the text that should appear for each one.

    Search my posts on this forum an you’ll find a fair amount of info on this.

     

    #375714 Score: 0
    Profile photo of The AV-ator
    The AV-ator
    Member
    advanced
    contributor
    beginner
    intermediate
    friend finder
    wise owl
    curious george
    profile
    picture perfect
    Group Member
    12 pts
    @TheAv-ator

    It may be a little less elegant than the Scripting as mentioned above, but I think this can be accomplished with just text boxes and action groups – no complex variables or conditions necessarily needed.

    – Just put the text you want to appear for each selection in its own text box (hidden) – which would be 18 boxes based on your attachments.
    – Then create action groups that hide all the other text boxes and shows which ever one you want shown.
    – Then your list is just a selection to call whichever action group is needed.
    (that is, if I correctly understand what you’re trying to do)

    #375781 Score: 0
    Profile photo of Dennis Peteranderl
    Dennis Peteranderl
    Member
    beginner
    intermediate
    friend finder
    wise owl
    profile
    contributor
    curious george
    @dpeteranderl9908

    I had a look at your file. Everything was actually fine with it … you just had some empty spaces behind some of your values and you could have added the “- ” before the values – e.g. ” – RC” instead of “RC” – to make sure you don’t have two texts being shown simultaneously.

    #376004 Score: 0
    Profile photo of Andy Krayenhagen
    Andy Krayenhagen
    Member
    beginner
    intermediate
    advanced
    picture perfect
    profile
    friend finder
    curious george
    wise owl
    contributor
    2 pts
    @akrayenhagen9721

    Yes I got the List to work.

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.