Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello,
I have an excel file which I address from within C#: write data to it execute a macro in it (using cells which use the YearFrac function from the add-in "Analysis Toolpack") read back the results. After exporting data to the excel the add-in "Analysis Toolpack" seems to have problems: All cells using this function (example: = YearFrac(A1, B1, 2) where cells A1 and B1 contain dates) contain the value #Name? direction to the solution? After unchecking and checking the add-in (under Tools = Add-Ins...), I suddenly get an additional menu option Tools = Data Analysis... (which was missing before) Then I click this menu option Data Analysis.. and from the moment the popup on this opens I see the cells with formulas using YearFrac, returning correct results. (I then close this popup Data Analysis.. and all is solved, until I write my data in the excel file again) Laura G. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
When starting Excel via automation, which I imagine is what you are doing,
add-ins are not automatically loaded. Hence any function in such add-ins are not known to Excel. Load the addin in your code. NickHK "Laura G." <Laura wrote in message ... Hello, I have an excel file which I address from within C#: write data to it execute a macro in it (using cells which use the YearFrac function from the add-in "Analysis Toolpack") read back the results. After exporting data to the excel the add-in "Analysis Toolpack" seems to have problems: All cells using this function (example: = YearFrac(A1, B1, 2) where cells A1 and B1 contain dates) contain the value #Name? direction to the solution? After unchecking and checking the add-in (under Tools = Add-Ins...), I suddenly get an additional menu option Tools = Data Analysis... (which was missing before) Then I click this menu option Data Analysis.. and from the moment the popup on this opens I see the cells with formulas using YearFrac, returning correct results. (I then close this popup Data Analysis.. and all is solved, until I write my data in the excel file again) Laura G. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
This works
Thanks :-) Laura G. "NickHK" wrote: When starting Excel via automation, which I imagine is what you are doing, add-ins are not automatically loaded. Hence any function in such add-ins are not known to Excel. Load the addin in your code. NickHK "Laura G." <Laura wrote in message ... Hello, I have an excel file which I address from within C#: write data to it execute a macro in it (using cells which use the YearFrac function from the add-in "Analysis Toolpack") read back the results. After exporting data to the excel the add-in "Analysis Toolpack" seems to have problems: All cells using this function (example: = YearFrac(A1, B1, 2) where cells A1 and B1 contain dates) contain the value #Name? direction to the solution? After unchecking and checking the add-in (under Tools = Add-Ins...), I suddenly get an additional menu option Tools = Data Analysis... (which was missing before) Then I click this menu option Data Analysis.. and from the moment the popup on this opens I see the cells with formulas using YearFrac, returning correct results. (I then close this popup Data Analysis.. and all is solved, until I write my data in the excel file again) Laura G. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Difficulty Loading Analysis Toolpack in 08 | Excel Discussion (Misc queries) | |||
Excel 2003 analysis toolpack add-in | Excel Discussion (Misc queries) | |||
Analysis ToolPack For Excel 2002 | Excel Discussion (Misc queries) | |||
Problem using analysis toolpack when automatically running excel | Excel Programming | |||
Problem using analysis toolpack when automating EXCEL | Excel Programming |