Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sorting in Excel
Message
De
29/01/2004 14:00:59
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
29/01/2004 12:37:30
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Divers
Thread ID:
00871887
Message ID:
00871943
Vues:
19
>Can anyone tell me how to automate a sort in excel? I've tried several varieations on the macro code but can't quite seem to get it right.
>
>Here's my latest try which doesn't work.
>
>oSheet.Range("A6:W155").Sort(_Key1:=oSheet.Range("D6"))
>
>Thanks in advance for any help.

I think VFP will have trouble with the named parameters; try to use parameters by position. In case of doubt, click on "Sort" in the macro editor (in Excel), and press F1, to get alternative syntaxes.

If the macro editor gives you named parameters, AFAIK, these are usually in the correct order for the un-named version; that is, you can probably just omit "_Key1:=".
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
Répondre
Fil
Voir

Click here to load this message in the networking platform