Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Need Help with Replicating a Row in Excel
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Divers
Thread ID:
00463948
Message ID:
00463952
Vues:
13
Hi Michael,

>I need to convert the following VBA statement to use in FoxPro. I am >unfamiliar with the correct references to properly replace the ":=" functions. >This function replicates the formulas from one row to the next.

>oExcel.Selection.AutoFill Destination:=Rows("13:14"), Type:=xlFillDefault

If you look up AutoFill in Excels VBA editor, it shows the following as a prototype for the AutoFill function:

Function AutoFill(Destination As Range, [Type As XlAutoFillType = xlFillDefault])

Any functions in excel I've ever come across that use the := syntax, require you to pass these values as parameters to a function. Thusly, yours would look like:

oExcel.Selection.AutoFill( oExcel.Selection.Rows("13:14"), 0 )

... where oExcel.Selection.Rows("13:14") is representative of the range you are performing the Autofill function on and

... 0 is an enumerated value in Excel represented by the value XlAutoFillType
Paul A. Busbey
Victoria Insurance
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform