Running VBScript from tm1

Post Reply
late.vaibhav
Posts: 25
Joined: Mon Dec 09, 2013 1:00 pm
OLAP Product: tm1
Version: 9.5.2, 10.2.2
Excel Version: 2007 2010
Location: India
Contact:

Running VBScript from tm1

Post by late.vaibhav »

Hi

I want know the correct method to pass the parameter to vbScript,Currently i am using following code to send parameter to .vbs file which is created to sent mail.
arguments = 'CScript D:\Mail\SendMailOther.vbs '|sSMTPSvr |' ' | sSender | ' "'|pRecipient|'" "'|pSubject|'" "'| pBody | '"' ;
EXECUTECOMMAND(arguments ,1);


When i rum the vbs file after hard-coding the parameters it works but when i try to send the parameters from TI it doesn't give any error message but my mail is not get triggered.

I am using following code in my Vb Script:
SMTPServer = WScript.Arguments(0)
Mail_from = WScript.Arguments(1)

Thanks & Regards
Vaibhav Late.
babytiger
Posts: 78
Joined: Wed Jul 31, 2013 4:32 am
OLAP Product: Cognos TM1, EP, Analyst
Version: 10.2.2
Excel Version: 2013
Location: Sydney AU

Re: Running VBScript from tm1

Post by babytiger »

TI wouldn't give out any error message, since the command executed is a correct syntax vbs command.

I would suggest test out the command from a command line, run cmd, and enter >D:\Mail\SendMailOther.vbs with parameters between double-quotes. If there's anything wrong with the vbs, you will get an error.
MK
Post Reply