Hello,
I am creating a CUSTOMGUI_CYCLE with my own attributes using getDDescription function. Everything goes fine until the point where I want to change the selected item. Assume that I have the following code, the Item with id 0 will be selected by default. Is there any way that I can change this? Like after a specific action the Item 1 will be selected? I tried many things but I could not find the right one. the .SetInt32(Id,value) method does not seem to work for this case as well.I also tried GetDParameter and other possible ways to do this but still could not solve this.
BaseContainer settings = GetCustomDataTypeDefault(DTYPE_LONG);
settings.SetString(DESC_NAME, "Drop Down"_s);
settings.SetInt32(DESC_CUSTOMGUI, CUSTOMGUI_CYCLE);
// add cycle elements
BaseContainer items;
items.SetString(0, "Item 1"_s);
items.SetString(1, "Item 2"_s);
items.SetString(2, "Item 3"_s);
settings.SetContainer(DESC_CYCLE, items);
Thank you.