G
GS
I ma stupped.
int idx = viewRegexOptionBindingSource.Find("regexoption",
textBoxRegexOption.Text); // works , no problem here
if (idx < 0) idx = 0;
bFormLoading = true;
regexOptionListBox.SetSelected(idx, true);
int idx2 = viewRegexCategoryBindingSource.Find("regexcategory",
textBoxRegexCategory.Text); //oops I got error:
Input string was not in a correct format.
and I don't see any difference in first find from the last find above,
I have tried retype the statment from scratch, but I sitll have the same
problem.
If I mis-type the search string regexcategory to something else like adding
a letter a, I will get as message of
DataMember property 'regexcategorya' cannot be found on the DataSource.
int idx = viewRegexOptionBindingSource.Find("regexoption",
textBoxRegexOption.Text); // works , no problem here
if (idx < 0) idx = 0;
bFormLoading = true;
regexOptionListBox.SetSelected(idx, true);
int idx2 = viewRegexCategoryBindingSource.Find("regexcategory",
textBoxRegexCategory.Text); //oops I got error:
Input string was not in a correct format.
and I don't see any difference in first find from the last find above,
I have tried retype the statment from scratch, but I sitll have the same
problem.
If I mis-type the search string regexcategory to something else like adding
a letter a, I will get as message of
DataMember property 'regexcategorya' cannot be found on the DataSource.