Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi gurus,
I do have a requirement where I need to disable list box 2 when list box 1 is selected, I'm able to hide listbox 2 when
listbox 1 is selected using GetSelectedCount function and using conditional function, but I want to show it and disable selection, I know it can be down using Actions and trrigger, can someone please explain how to achieve this.
attaching sample qvw.
Any help is highly appreciated.
Hi kumar, I don't know how to disable, as a workaround you can remove selections and hide the list box, to remove selections: in document properties (Ctrl+Alt+D)--> Triggers --> Select the list box1 field in field events --> On Select;add action --> Add --> Selection;Delete field --> In Field text box set the name of the listbox2
i avoided locking triggers etc. and put something a bit more obvious to the user. (conditional text box that overlays the 2nd list box)
Hi Jonathan,
I liked your solution, also can you please let me know how to disable the listbox selection, I tried to use lock filed trigger, on field selection, but it doesnt work..am I missing anything,
please let me know
I think its because you can't lock a field unless there is a selection in it.
In your case you are trying to lock a field that has no selected value.
Do you want to apply a selection on the resulting 'possible values' (in white) and lock those ?
Here is an example of doing that with 2 actions fired based on the trigger of a selection of a value in the first list box.
Hi Jonathan,
Thx for response. I made field selection and still list box doesn't get locked. please help.
If the transplanted sample isn't working in your app can you share some screenshots of the actions you creates as well as the expression of the 'select in field' search mask?
Also do the values have spaces in them ? The sample did not but if your app does then a change is needed
have you tried making the second list box READONLY. The way you have the conditional visibility of List box 2 based on selection of values in List box 1 same way you ca have the second list box readonly. so that noone can select anything from that list box.
Hi Sudeep,
read only disables the selection of listbox 2 completely, I want to disable the selection only when list box 1 is selected
Hi Kumar, Sudeep solution is a good idea, you already know how to hide, you can have two listbox2, one read only and one selectable, when there are selections in listbox1 you can hide the "selectable" listbox2 and un-hide the read-only list box