Information générale
Catégorie:
Contrôles ActiveX en VFP
Versions des environnements
Network:
Windows 2003 Server
>I have a table table that contains RTF phrases and I want to locate a RTF-string in there.
This means that table may contain a phrase like (in RTF):
Productos petrol¡feros n.o.s.
>
>And I need to find the ¡ character (in RTF as well)
>
>For that I do the following:
>1) I copy the data from the field in an instance of the rtf-control (lortf1)
>2) I copy the data from the locatestring in an other instance of the rtf-control (lortf2)
>3) I ask the lortf1 if the second lortf2.textrtf is present.
>
>For this I use the lortf1.find(lortf2.textrtf,,,0) method.
>I guess I must be doing things wrong because the find method never returns a hit.
The property loRTF2.TextRTF returns/sets the contents of the RTF control -- you should set here the text you want to search for; i.e., loRTF2.Find("¡",,,0). Also, I believe this method will not find RTF formatting codes if you embed it into the text to find.
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement