从Hyperion服务器发送电子邮件

时间:2012-06-25 23:34:56

标签: email hyperion

我正在尝试在记录数为0时从hyperion服务器发送电子邮件。我正在onPostProcess()中编写脚本代码。

var dtm_current = new Date();
Application.ExecuteBScript("Set BrioQuery, Mail, 'Internet Mail', mailserverwithoutquotes,fromid'"); //note that mailserver name is given without quotes and 
//from id does nt have starting quote
Application.ExecuteBScript("Export Section Root.'Results', OfficeMHTML, 'job_output', Silent, email, 'Testing Email action', 'This is a test of the email action. \n\n\n', UTF-8, To, tomailid'");
Console.Writeln ( "Post Process Script complete:"+dtm_current );

我收到错误 通过电子邮件将“结果”部分发送为“Microsoft Office Web Archive”: com'

导出失败。错误:连接无法找到主机127.0.0.1。端口25上的SMTP服务器是? (错误代码= 146)

问题我:为什么尝试连接到localhost而不是指定的电子邮件服务器

1 个答案:

答案 0 :(得分:0)

我有这个工作。

var dtm_current = new Date(); Application.ExecuteBScript(“设置BrioQuery,Mail,'Internet Mail',emailserverwithoutquotes,'fromemailid'”); var count = 1 * ActiveDocument.Sections ['R-Results']。RowCount;

Console.Writeln(计数); if(count> 0){ Application.ExecuteBScript(“Export Section Root.'R-Results',csv,'job_output',Silent,email,'Testing Email action if if','这是对电子邮件操作的测试,如果。\ n \ n \ n' ,UTF-8,To,'tomailid'“); } 其他{ Application.ExecuteBScript(“Export Section Root.'R-Results',csv,'job_output',Silent,email,'Testing Email action else','这是对其他电子邮件操作的测试。\ n \ n \ n' ,UTF-8,To,'tomailid'“); }

相关问题