APL and Excel ActiveX control 
Author Message
 APL and Excel ActiveX control

Communicating with Excel seems to be a perennial topic.  Using Dyalog 9
under Win2K, the OLE server passes arrays back and forth as expected; but
the MSOWC ActiveX control with the "same" methods/properties only seems to
understand scalars.

First, using the OLE server Excel.Application:

      ActiveSheet.(Range'A1:A2').Rows.Count
2
      ActiveSheet.(Range'A1:A2').Value
 DataInA1
 DataInA2
      ActiveSheet.(Range'A1:A2').Value <- 2 1 rho 11 22
      ActiveSheet.(Range'A1:A2').Value
11
22

The above looks normal.  Now with the ActiveX Spreadsheet control, which
seems to have the same docs as the OLE server:

      ActiveSheet.(Range'A1:A2').Rows.Count
2
      ActiveSheet.(Range'A1:A2').Value
DataInA1
      ActiveSheet.(Range'A1:A2').Value <- 2 1 rho 11 22
DOMAIN ERROR
      ActiveSheet.(Range'A1:A2').Value <- 2 1 rho 11 22
     ^
      ActiveSheet.(Range'A1:A2').Value
DataInA1

It knows the correct shape of the range (2 rows), but the Value property
appears broken both for reading and writing.

Suggestions welcome.

Joe



Tue, 04 Jan 2005 05:46:39 GMT  
 APL and Excel ActiveX control

Quote:
> Communicating with Excel seems to be a perennial topic. Using Dyalog
> 9 under Win2K, the OLE server passes arrays back and forth as
> expected; but the MSOWC ActiveX control with the "same"
> methods/properties only seems to understand scalars.

There seems to be no serious documentation of the object model of the
Spreadsheet Web Control on Microsoft's web pages. I only found a
description of its capabilities at:
http://msdn.microsoft.com/library/en-us/modcore/html/deovrUnderstandingS
preadsheetControl.asp?frame=true

Quote:
>       ActiveSheet.(Range'A1:A2').Value <- 2 1 rho 11 22 DOMAIN ERROR
> It knows the correct shape of the range (2 rows), but the Value
> property appears broken both for reading and writing.

> Suggestions welcome.

Somewhat supported by the paragraph in the listed document, that goes:
"All of the functionality in the Spreadsheet component uses Excel's
properties, methods, and events. In some cases, the full functionality
of an Excel method is not supported (for example, password protection),
but the object model syntax is identical to Excel." my gut feeling is
that the MSOWC does not support array properties. One thing you can try
is to try the same thing you are trying to do from APL in VB (or VBA).
If you can do it there, then it could be that Dyadic's OLE engine needs
a little tuning. If you can't do it from VB or VBA then, I'd say,
there's no hope and you are forced to loop.

Sorry I cannot help you more.
--

Homepage: currently offline

<<<All I Ever Learned, I Learned From Anime: ---
   Angels constantly lose feathers.>>>



Tue, 04 Jan 2005 16:19:18 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. APL and Excel ActiveX control

2. CFW 2.0 and Microsoft Internet Control Pack Beta 2 ActiveX Controls

3. Excel activex, setting multiple cells in a column range

4. Strange behaviour with ActiveX invoke node and Excel

5. Closing Excel with ActiveX causes problem

6. Howto call a vi by activeX or DLL from Excel

7. import Excel Template into LV ActiveX container

8. Closing Excel with ActiveX causes problem

9. How to save then quit excel using activeX

10. Cannot open Excel using Activex

11. excel operation using activex

12. Excel-Activex Question for Alberto (or anyone else)

 

 
Powered by phpBB® Forum Software