I'm looking for some help, I'm new with C# and i'm trying to make a combobox
with custom indexes, I was adding the items
this way
mycb.Items.Add("My value 1");
mycb.Items.Add("My value 2");
by this way I get these indexes by default 0 and 1
so I try to give the indexes that I want to the CB
using Insert
mycb.Items.Insert(5,"My value 1");
mycb.Items.Insert(6,"My value 2");
this way the CB
should have the indexes 5 and 6
but this is not working because when I select one of those options this error appeared
invalid argument=value of '5' is not valid for 'index'
It works when I add consecutive indexes starting by 0 but that is not what I want, how can I add the indexes that I want to the CB
without having this issue? I hope you can help me, thanks.