Consider some list:

list = {"A","B","C","D"}

How to select only particular values from it using a dynamic dialog window that prevents the code below it from evaluating before the choice is made (by using e.g. DialogInput)?


1 Answer 1


You can use TogglerBar.

selectionDialog[list_] := 
 DialogInput[{choice = {}}, 
  Column[{TogglerBar[Dynamic[choice], list], 
    Button["OK", DialogReturn[choice]]}]]

list = {"A", "B", "C", "D"};

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.