Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
OLE Automation - Excel
Message
De
23/07/2007 09:10:35
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
23/07/2007 03:50:53
Ed Hizon
Skswood Sdn. Bhd
Kuala Belait, Brunei
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Divers
Thread ID:
01242686
Message ID:
01242744
Vues:
10
>Dear all,
>
>I would like to know the equivalent code to VFP if using OLE the command in Excel for "Find" The following will give an error:
>
>XLApp = createObject('excel.application')
>XLApp.Visible = .t.
>*XLApp.WorkBooks.open('c:\xxx\xxxx.xls')
>
>
>XLSheet = XLApp.ActiveSheet
>
>xlsheet.range("h:h").select
>
>xlsheet.selection.find.text="ABCD"
>
>Please advise.
>
>Thanks.
>
>Ed

Selection is a property of Excel.Application not Sheet.

xlsheet.application.selection.find.text="ABCD"

or:

xlsheet.range("h:h").find.text="ABCD"

Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform