Re: RichEdit and findText
- Posted by Derek Parnell <ddparnell at bigpond.com> Nov 16, 2004
- 443 views
CoJaBo wrote: > > Derek Parnell wrote: > > > > Pete wrote: > > > > > > Its late so I hope someone can supply the answer to my stupid question > > > while I sleep!! > > > I have a RichEdit in which I'm doing a findText. The findText works > > > fine when searching for a single character, but fails to find it if I am > > > searching for more than one character.. > > > > > > i.e in the RichEdit I have "7028" > > > > > > This works fine:- > > > fnd = findText ( RE, "7", {0,-1}, findDown) > > > so does this > > > fnd = findText ( RE, "0", {0,-1}, findDown) > > > but.. > > > fnd = findText ( RE, "7028", {0,-1}, findDown) > > > returns 0 > > > Adding the findWholeWord flag also makes no difference.. > > > > > > I'm sure I'm doing something wrong but I can't see what.. Help! > > > > I think I know the problem. Find the 'findText()' function in > > the win32lib library and replace ... > > > > FT = struct_FINDTEXTEX( range[1], range[2], text, 0, 0 ) > > > > with ... > > > > FT = struct_FINDTEXTEX( range[1], range[2], text, 0, -1 ) > > > Will this be fixed in the next version? Don't know. Did this *actually* fix the problem? If so, I can put it in, so I'll wait for confirmation. If I get time today I'll test it myself but I'm a bit busy right now. > (also, when do you think the next version > will be ready?) I've tentatively pencilled in 30-Nov for the next release. It may happen earlier, as all I've got to complete is a tiny bit of documentation and a full regression test (plus this fix if it works). Actually I've started the testing but I managed to get Judith's IDE to trip over. -- Derek Parnell Melbourne, Australia