Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Searching a Word document
Message
De
01/02/2004 15:00:47
Barry Newton
Plan International
London, Royaume Uni
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Titre:
Searching a Word document
Divers
Thread ID:
00872799
Message ID:
00872799
Vues:
47
i'm using automation to manipulate a word document and am having trouble searching a document that contains textboxes.

i use this code in my search:
------------------------------------------
oWord = CreateObject( "Word.Application" )
oWord.Documents.Open("g:\filename.doc")
oRange = oWord.ActiveDocument.Range(0,0)
WITH oRange.Find
.Text = "AGE1"
.matchcase = .f.
.format = .f.
lfound = .Execute()
ENDWITH
RELEASE oRange
oWord.Quit
RELEASE oWord
------------------------------------------

if the text 'AGE1' is in a textbox then this doesn't work, if i search for a textstring in the 'normal' text then it works.

q. how to find the 'textbox text'?

many thanks in advance!
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform