Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Worksheet function - array result, C++
Hi All,
I'd like to use C++ to: 1. Write addin which exposes function available from worksheet 2. Function has one parameter which is a query to database returning data (size of data in unknown until query is launched) 3. Insert result into cells. I've been trying with Excel and COM addins and I can't write results to cells when I call function. The problem doesn't exists when it is a macro. Then I can write to any cell on the sheet. Is it possible to handle it in a different way? Any help would be much appreciated. Thanks Kamil. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Worksheet function - array result, C++
Functions can only return results to the cells they occupy:
If you array-enter (Control-Shift-Enter) a Function into multiple cells then the function can return an array of values to those cells. Otherwise you have to use a Sub called from an event. -- Charles ___________________________________ The Excel Calculation Site http://www.decisionmodels.com "kamil jaskiewicz" wrote in message ... Hi All, I'd like to use C++ to: 1. Write addin which exposes function available from worksheet 2. Function has one parameter which is a query to database returning data (size of data in unknown until query is launched) 3. Insert result into cells. I've been trying with Excel and COM addins and I can't write results to cells when I call function. The problem doesn't exists when it is a macro. Then I can write to any cell on the sheet. Is it possible to handle it in a different way? Any help would be much appreciated. Thanks Kamil. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Worksheet function - array result, C++
Thanks Charles,
I don't want to use array formulas because it is not convenient way (you don't know what range you have to select). I'll try with events. "Charles Williams" wrote: Functions can only return results to the cells they occupy: If you array-enter (Control-Shift-Enter) a Function into multiple cells then the function can return an array of values to those cells. Otherwise you have to use a Sub called from an event. -- Charles ___________________________________ The Excel Calculation Site http://www.decisionmodels.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Non-Array Function result in non-accurate values | Excel Discussion (Misc queries) | |||
Non-Array Function result in non-accurate values | Excel Worksheet Functions | |||
query result through array on worksheet | Excel Programming | |||
Using address function result in an array | Excel Worksheet Functions | |||
function array result - .xll - sdk - XLOPER - example code? | Excel Programming |