Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Set the Width of an Excel Column
Message
De
02/09/2003 18:27:38
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
02/09/2003 18:20:58
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Divers
Thread ID:
00825508
Message ID:
00825510
Vues:
18
>My mind has gone blank. How can I set the width of an Excel Column through Automation?

You have to set the width of a cell. The following is from one of my programs:
with oSheet
  .Cells(1,1).ColumnWidth = 6
  .Cells(1,2).ColumnWidth = 30
  ...
endwith
The above example sets the ColumnWidth of columns A and B. I prefer the RC (row-column) syntax, because it is easier to manipulate numbers than letters for columns.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform