--
You received this message because you are subscribed to the Google Groups "Excel-DNA" group.
To unsubscribe from this group and stop receiving emails from it, send an email to exceldna+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/exceldna/6a8e8135-7808-4fa1-8e30-47cd8261a806n%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/exceldna/8af4a921-701a-455b-94a6-e36353ed83ecn%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/exceldna/a85e2a7c-c96f-467b-84fd-42dd14fa8ccbn%40googlegroups.com.
Just call it late-bound.
If ‘range’ refers to the one top-left cell where you want to anchor the dynamic array.
Then call:
dynamic rangeDyn = range;
rangeDyn.Formula2 = raySegments;
Range.Formula2 is probably not in any ‘package’ you’re looking at, but it is a method on the Range COM class in versions of Excel that support Dynamic Arrays.
And you have to use it to get the non-@ behaviour you want for setting dynamic array values into a cell.
-Govert
To view this discussion on the web visit https://groups.google.com/d/msgid/exceldna/c280bd62-55ae-44db-8318-c0770e4d8994n%40googlegroups.com.
I guess the things that is disabled by the new setting is the macro sheet you use for your example.
That macro sheet then has a cell with =DIALOG.BOX(F9:L19).
But when called as xlcDialogBox through the C API it still works fine.
Do you think I have it right?
To view this discussion on the web visit https://groups.google.com/d/msgid/exceldna/4a16d869-c7b3-4719-bc36-f0649374d283n%40googlegroups.com.
dynamic rangeDyn = range;
rangeDyn.Formula2 = raySegments;
Do you have a suggestion on how to fix this? I'm using packages Excel-Dna 1.5.1 and NetOfficeFw.Excel 1.8.1
Thanks, Andy
Hi Andy,
NetOffice wraps the COM object model in a .NET object model.
So even if the COM object exposes the Formula2 property, the NetOffice object model might not.
You probably don’t need to use NetOffice anymore, since .NET 4 supports the “Embed Interop Types” option.
But even with a reference to the Excel PIA assembly, I’m not sure whether the Formual2 is exposed for early-binding, so you might still need the dynamic in that case.
To view this discussion on the web visit https://groups.google.com/d/msgid/exceldna/8bee4be1-a632-42fc-882f-09ff63006702n%40googlegroups.com.