Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Passing Array to Excel - how?
Message
From
16/01/2003 15:18:06
 
 
To
16/01/2003 15:11:48
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
00742597
Message ID:
00742603
Views:
17
I found the answer - pass the array preceded by the @ sign...

>The following VBA correctly subtotals the selected range within Excel...
>
>oExcel.Selection.Subtotal GroupBy:=2, Function:=xlSum, TotalList:=Array(15, 16, 17, 18, 19), Replace:=True, PageBreaks:=False, SummaryBelowData:=True
>
>I am trying to get Foxpro to do the same thusly, but only the first column gets subtotaled.
>
>DIMENSION subtotal_array(1,4)
>subtotal_array(1,1) = 16
>subtotal_array(1,2) = 17
>subtotal_array(1,3) = 18
>subtotal_array(1,4) = 19
>
>oExcel.Selection.Subtotal (2, xlSum, subtotal_array, .t., .f., .t.)
>
>
>Can anybody help me understand how to successfully pass an array to Excel from VFP?
>
>Thanks in advance for any assistance...
>
>Andrew
On a CLEAR day you can see forever.
Previous
Reply
Map
View

Click here to load this message in the networking platform