Page 1 of 1

Vb.net with Pax

Posted: Tue Sep 25, 2018 9:37 am
by kavitha2002
Hello Everyone,

I am looking for some docs or input for integrating Tm1 Pax with Vb.net application. Earlier vb.net application was working with Tm1 perspectives. Now would like to convert Tm1 perspectives to Pax.

Any ideas or inputs are much appreciated.

Thanks

Re: Vb.net with Pax

Posted: Tue Sep 25, 2018 11:47 am
by orlando
Hi,

as far as i know, there is no VB API for PaX - you have to use the Rest API.

Regards,
orlando

Re: Vb.net with Pax

Posted: Tue Sep 25, 2018 12:11 pm
by kavitha2002
Hi orlando,

I will put the question in different way, I want to open excel from vb.net application via code, and after opening the excel I have to connect to Tm1 instance for Pax using Tm1 macro functions or TM1 CognosOfficeAutomationObject.bas.

I think currently Pax doesnt support Macro functions, it support only API

Reference:

Re: Vb.net with Pax

Posted: Tue Sep 25, 2018 12:20 pm
by orlando
Hi,

yes, there is no VBA API for Pax anymore.

Sorry, i don't know anythink about the TM1 CognosOfficeAutomationObject.bas.

Regards,
orlando

Re: Vb.net with Pax

Posted: Tue Sep 25, 2018 1:39 pm
by kavitha2002
Anyone has idea about CognosOfficeAutomationObject.Logon() API in VBA for TM1 Pax.

For IntegratedSecurityMode 1,
CognosOfficeAutomationObject.Logon("IBM Cognos Server Url", "username", "password", "pmhub host/TM1 Server instance") api is used to connect to Tm1 server instance.


But i dont know what url to give in place of parameters 'IBM Cognos Server Url' and 'pmhub host',

I gave IBM Cognos Server Url as http://92.168.40.100 paw IP address and pmhubhost as host where Tm1 server is running,

But doesnt connect. Any help is appreciated.

Re: Vb.net with Pax

Posted: Tue Sep 25, 2018 8:05 pm
by bgregs
Hi Kavitha,

This is actually still possible, but the object has changed from "CognosOfficeAutomationObject" to "CognosOfficeAutomationExample". Please see page 197 of the following documentation:

https://www.ibm.com/support/knowledgece ... ug_cxr.pdf

Re: Vb.net with Pax

Posted: Wed Sep 26, 2018 6:51 am
by David Usherwood
Hope Revelwood won't mind me posting their writeup of PAX and VBA (I know, not vb.net, but it is relevant IMO):
https://knowledgecenter.revelwood.com/i ... api-calls/

Re: Vb.net with Pax

Posted: Wed Sep 26, 2018 8:35 am
by kavitha2002
Hi @bgregs,,

I have tried with CognosOfficeAutomationExample just today morning, but that also doesnt works.

Tried the below:

CognosOfficeAutomationExample.Logon("http://192.168.40.100", "admin", "admin", "localhost/Tm1 server instance")

I dont know what could the first parameter. It stated that first parameter as IBM cognos server Url.

I tried with http://localhost:9510, http://localhost:8001, but nothing works:( what url i have to give?

One thing which i noticed is using http://localhost:9510 parameter, show all the Tm1 instances but none has connected.

Hi @David Usherwood,

I have gone through that link as well, but those steps I have already tried, its working except LOGON for IntegratedSecurityMode=1.

Re: Vb.net with Pax

Posted: Wed Sep 26, 2018 11:47 am
by bgregs
Hi Kavitha,

Please see this link to the documentation: https://www.ibm.com/support/knowledgece ... ethod.html

Just wanted to reiterate, but there is a highlighted note stating:
Mode 1 authentication requires the combination of the PM Hub host and the TM1 Server as the namespace, separated by a forward slash (/). If your namespace contains a forward slash, the logon is interpreted as a Mode 1 authentication attempt.
Although it appears you've already tried that in one of your examples.

It looks like you're almost there, but I don't think you're properly calling the "url" parameter. Take a look at this page for a more in depth overview of the port and URI settings:
https://www.ibm.com/support/knowledgece ... eauri.html

Also note that in the IBM examples they are making calls to cognos.cgi (Common Gateway Interface) in the URL, although it is unclear to me if this is only needed for CAM so you would need to play around with it a bit.

Code: Select all

bResult = CognosOfficeAutomationObject.Logon
("http://localhost/ibmcognos/cgi-bin/cognos.cgi",
"Administrator", "CognosAdmin", "Production")

Re: Vb.net with Pax

Posted: Wed Sep 26, 2018 12:19 pm
by kavitha2002
Hi @bgregs,

Thank you.

I found it, it worked well. Its because of the case-sensitivity of fourth Parameter: example : host/TestInstance.

Below worked:

CognosOfficeAutomationExample.Logon("http://192.168.40.100", "admin", "admin", "localhost/Tm1 server instance")

Paw IPaddress : http://192.168.40.100

Loads of thanks for response.

Re: Vb.net with Pax

Posted: Sat Mar 02, 2019 12:37 am
by hadimulam
What is the namespace here? I am trying to establish connection but I'm unable to do so. Please help

Re: Vb.net with Pax

Posted: Thu Mar 07, 2019 1:23 pm
by kavitha2002
Sorry for the late reply.

If Integratedsecuritymode=1, then the 4th parameter namespace is Host/Tm1 Instance

Where 'Host' is in which machine the TM1 is installed and 'Tm1 instance' is instance under TM1

Example: Machine01/TestInstance is the namespace, but its case-sensitive.

For Integratedsecuritymode=5, then namespace is Active Directory namespace which we configured in cognos Analytics configuration.

Hope it may help.