I have a CheckedListBox1 that contains checked and unchecked Items.
What I am trying to do is to save everything into a vector.
Like below, I can save all Items Text into vector<string> TextInfo but what I am trying to
do is also for each Item save if that specific Item was checked or unchecked.
How is this possible to do, because this might not be a String^ info that I can save into a String^ I beleive ?
I can get the CheckState for each Item like the codeline below.
What I wonder is how it will be possible to save the checkedstate for each Item.
I might need a vector in any way for this ?
CheckedListBox1->GetItemCheckState(i);
//i is the index in a for loop like the code below
String^ Temp = "";
std::string temp = "";
std::vector<string> TextInfo;
if (CheckedListBox1->Items->Count > 0)
{
for(int i = 0; i < CheckedListBox1->Items->Count; i++)
{
Temp = CheckedListBox1->GetItemText(CheckedListBox1->Items[i]);
MarshalString(Temp, temp);
TextInfo.push_back(temp);
}
}