Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Excel Macro Question
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Titre:
Excel Macro Question
Divers
Thread ID:
00479873
Message ID:
00479873
Vues:
63
How to I pass a parameter to an Excel macro?

The code I have is:


cFileName = GETFILE("txt")

oExcel = CREATEOBJECT("Excel.Application")
oExcel.Workbooks.Open("MyWorkbook.Xls")

oExcel.Application.Run("MyWorkbook!MyMacro(" + cFileName + ")")


The last line is failing.

Can anyone tell me the correct syntax?

TIA
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform