Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Excel to recognize FoxPro memo fields?
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00393509
Message ID:
00394386
Vues:
11
I'm still a newbee at this, but let's see what I can come up with. The first thing is that you have to translate the VBA into valid VFP code. So, "False" needs to become ".F.".

I would suggest looking up the "SaveAs" function in the automation help and see if you can figure out the format. As it is, I can see that VFP is going to choke. If everything starting with "FileName" are parameters, then maybe putting () around it would help. You'd also need quotes around each parameter. That should be enough to get Fox to accept it, but whether Excel would accept it, I don't know.

If that doesn't work, a new post in the OLE Automation category should get help from someone more advanced than me. I've only done really basic tinkering with other peoples' code. :)

Hope that helps,

Michelle


>thanks for the info and code. works well. but now i want to save the workbook as a specific name in a specific folder. went into excel, recorded a macro and then look at the VB code. i added the oExcel. before the ActiveWorkbook.Saveas. but i get a syntax error when i execute it in the command window.
>
>oExcel = CREATEOBJECT('Excel.Application')
>oExcel.workbooks.add
>oExcel.ActiveWorkbook.SaveAs FileName:="C:\Book3.xls", FileFormat:=xlNormal, Password:="", WriteResPassword:="", ReadOnlyRecommended:=False, CreateBackup:=False
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform