Accessing a Statistica Macro from an Excel Macro - Statistica Visual Basic - Statistica - Dell Community

Accessing a Statistica Macro from an Excel Macro

Accessing a Statistica Macro from an Excel Macro

This question is not answered


I wrote a macro in Statistica that generates line plots and summarises them in a word report . The input data is generated with an macro in Excel and automatically imported into Statistica by running the graphing macro in Statistica. So I have 2 macros: 1 macro for input data generation in Excel and another macro for graphing in Statisitca.

Is there a way to combine both macros in the excel macro, so that the graphing macro in Statisitca is accessed by Excel. All I need from the Statistica analysis is the word report containing the graphs.

I would really much appreciated if you share your ideas!

Many thanks,


All Replies
  • Hi Tomato,

    You can call STATISTICA's functions and analyses from a VBA macro by adding a reference to STATISTICA's libraries. Have a look at this page.

    Hope this helps.

    Mário Falcão

  • Hi Mário,

    My Statistica macro is quite long and I don't know which parts of the macro I need to transfer to my excel macro. Is there an easier way to call the macro. I'm thinking of a command that simply calls the Statistica macro by its particular name and runs the macro from my excel macro. The excel macro does not necessarily need to run the Statistica macro in the background, so that you don't even know that it was run.... If it does run the Statistica macro in the background this would be the perfect solution, but first of all I just want to save the step of opening Statistica and starting the macro in Statistica.



  • Hi T,

    It seems that STATISTICA needs to be the driver of your SVB macro.

    Here is an idea. Your Excel VBA can call STATISTICA app (as an external Windows program, not via Type Library reference) with a command line switch "runmacro", see :

    Would that work for you ?

    Another idea ... do all in STATISTICA macro, you can call Excel functions from SVB, if needed