andresfp14
New Contributor II

by the way, this is the code:

if not("val" in locals()):

dbutils.widgets.dropdown("A", "4",["1","2","3","4","5","6","7"], "text")

val=dbutils.widgets.get("A")

if (val=="5"):

dbutils.widgets.remove("A")

dbutils.widgets.dropdown("A", "4",["1","3","4","5","6","7"], "text")

print(dbutils.widgets.get("A"))

if (val=="3"):

dbutils.widgets.remove("A")

dbutils.widgets.dropdown("A", "4",["1","2","3","4","5","6","7"], "text")

print(dbutils.widgets.get("A"))