TM1APIFinalize problem

Post Reply
mitch23
Posts: 21
Joined: Thu Jan 29, 2009 11:32 am
OLAP Product: Planning Analytics
Version: 10.1
Excel Version: Office 365

TM1APIFinalize problem

Post by mitch23 »

I am trying to learn the TM1 API and will probably post a few questions here as I do. The firt problem I'm having is properly disconnecting and cleaning up the session. I have followed the example in the help file verbatim and use the function TM1APIFinalize as the final line. The problem is that I get a "Bad DLL Calling Convention" error. Any ideas?
mitch23
Posts: 21
Joined: Thu Jan 29, 2009 11:32 am
OLAP Product: Planning Analytics
Version: 10.1
Excel Version: Office 365

Re: TM1APIFinalize problem

Post by mitch23 »

It seems that I may have stumbled accross the answer. It appears that the declaration syntax in the help file is incorrect. The help file is:

Declare Function TM1APIFinalize Lib "tm1api.dll" ()

but it should be:

Declare Sub TM1APIFinalize Lib "tm1api.dll" ()
Post Reply