TM1-VBA-Addin in Excel wanted!

Post Reply
schlemiel29
Posts: 50
Joined: Tue May 08, 2012 8:29 am
OLAP Product: TM/1
Version: 11.8
Excel Version: Excel 365

TM1-VBA-Addin in Excel wanted!

Post by schlemiel29 »

Hi,
I try to use TM1-functions using VBA in Excel. Despite all research in forums and Google, I didn't get it.
When in VBA editor, I want to make a reference to an TM1 speciifc xla. But I only see the tm1p.xla. This is not enough. When running a statement like

Set TM1Server = CreateObject("TM1.ApplicationServer")

I get an error message. A dll or xla semes to be missing. I installed everything from the setup when installing TM1. It is an old version (2.0.9), where the file dates are from sep 2019.
So what can I do with the actual version of the software? Where is the missing link?
Thanks in advance
Dirk
User avatar
gtonkin
MVP
Posts: 1202
Joined: Thu May 06, 2010 3:03 pm
OLAP Product: TM1
Version: Latest and greatest
Excel Version: Office 365 64-bit
Location: JHB, South Africa
Contact:

Re: TM1-VBA-Addin in Excel wanted!

Post by gtonkin »

Please could you explain what you are trying to accomplish, may be easier to advise on the route to follow.
schlemiel29
Posts: 50
Joined: Tue May 08, 2012 8:29 am
OLAP Product: TM/1
Version: 11.8
Excel Version: Excel 365

Re: TM1-VBA-Addin in Excel wanted!

Post by schlemiel29 »

That's simple: I want to run a VBA macro in Excel using TM1 functions.

I think I missed something basically. Installation?
I read about finding some files with .bas in cognis folders to use them first, but I don't have these files on the drive nor the folders they should located in.
User avatar
gtonkin
MVP
Posts: 1202
Joined: Thu May 06, 2010 3:03 pm
OLAP Product: TM1
Version: Latest and greatest
Excel Version: Office 365 64-bit
Location: JHB, South Africa
Contact:

Re: TM1-VBA-Addin in Excel wanted!

Post by gtonkin »

In perspectives unless you are using the C API, you just use Application.Run("<macro", <par>,...)
This applies to functions like ELCOMP, DBRW, DBRA etc. that you may want to use in macros.

If you are using PAfE then you need to follow here: https://ibm.github.io/paxapi/#set-up
But based on you mentioning TM1p.xla, PAfE is not relevant.
schlemiel29
Posts: 50
Joined: Tue May 08, 2012 8:29 am
OLAP Product: TM/1
Version: 11.8
Excel Version: Excel 365

Re: TM1-VBA-Addin in Excel wanted!

Post by schlemiel29 »

Yes, it works. Thanks a lot!
Post Reply