RichViewEdit->SearchText Not finding word
Posted: Thu May 23, 2013 8:26 pm
Hello. I am getting mixed results when searching for the same word in a richviewedit control. My code does this:
loop through a dataset and with each iteration
clear and load a richviewedit from a blob field.
richviewedit->format();
richviewedit->SetSelectionBounds(0,richviewedit(0,richviewedit->GetOffsBeforeItem(0),0,richviewedit->GetOffsBeforeItem(0));
if (richviewedit->SearchText("DIAGNOSIS:", TRVESearchOptions() <<
rvseoMatchCase << rvseoDown)) {
...do something
}
The word DIAGNOSIS: is in each of the fields but the program only finds it sometimes. I can't figure it out. Richview 11 on bcb2007. I have tried all TRVESearchOptions as well as SearchTextA and W and still cannot get a consistent return of true from the if statement. Please help. Thanks.
loop through a dataset and with each iteration
clear and load a richviewedit from a blob field.
richviewedit->format();
richviewedit->SetSelectionBounds(0,richviewedit(0,richviewedit->GetOffsBeforeItem(0),0,richviewedit->GetOffsBeforeItem(0));
if (richviewedit->SearchText("DIAGNOSIS:", TRVESearchOptions() <<
rvseoMatchCase << rvseoDown)) {
...do something
}
The word DIAGNOSIS: is in each of the fields but the program only finds it sometimes. I can't figure it out. Richview 11 on bcb2007. I have tried all TRVESearchOptions as well as SearchTextA and W and still cannot get a consistent return of true from the if statement. Please help. Thanks.