Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Excel / VFP What the best way to create/import/export
Message
 
À
16/10/2002 12:00:00
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00711789
Message ID:
00711849
Vues:
14
You may have to Automate to an Excel Print Preview.
This means you will be working with Excel Page Setup (for Headers), Cell Merges (for fancy stuff) and Excels print Previews:
To force a print preview:
oExcel.ActiveWorkBook.PrintPreview()
To Build an Excel Header using automation
.ActiveSheet.PageSetup.RightHeader = cdow(date())+[ ]+cmonth(date());
+str(day(date()),3)+str(year(date()),5)+[:]+left(time(),5);
+Chr(10) + "Page &P of  &N" + Chr(10) + "Ref:&F"
Merge cell commands:
* Column Headers
.Range("E1:F1").Select
.Selection.MergeCells=.t.
.Selection.HorizontalAlignment=3
You can record Excel macros, and convert them to VFP compliant automation. I have a procedure I used a couple years back that you study as you work your project. I'll email a sample Excel Print Preview VFP Automation if it will help!


>What is the best way to create Excel/ import from XL / export to XL
> data between Excel and VFP . I looking for complex spreadheets,
> with headers subgroups/subtottals grandTotals at end of Excel.
>
> Any code, tools or suggestions ?
>
> Thanks
> George
Imagination is more important than knowledge
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform