Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Excel
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Titre:
Re: Excel
Divers
Thread ID:
00437163
Message ID:
00437173
Vues:
23
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>I'm trying to automate Excel from Foxpro.
>>The problem I'm having is..I'd like to to align center a range of cells.

>>I'm using..
>>oSheet.Range("A1:A1").HorizontalAlignment = xlCenter

>>But I dont know the numeric equivalent of xlCenter....
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

If you have VB loaded (or even one of the VBA-based products like Word or Excel itself) you can use the object browser to find information on constants.

For instance, in Excel, Alt+F11 brings you to the VBA editor, and F2 brings up the object browser. Search for the constant(s) you need and the info panel on the bottom gives the value.

The Object Browser is really an invaluable tool when undertaking work with automation, or using not-very-well documented components written in another language.
The whole problem with the world is that fools and fanatics are always so certain of themselves, but wiser people so full of doubts. - Bertrand Russell
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform