cancel
Showing results for 
Search instead for 
Did you mean: 

Can someone help me fix this ? When i execute all test cases and try to notify result using Outlook

SOLVED
Highlighted
Frequent Visitor

Can someone help me fix this ? When i execute all test cases and try to notify result using Outlook

 i am getting below Error :

 

Server execution failed, ClassID: {0006F03A-0000-0000-C000-000000000046} 18:11:42 Normal 38.79

 

this is my code 

def sendEmailReport(emailToList):

outlookObj = Sys.OleObject["Outlook.Application"]
outlookMsg = outlookObj.CreateItem(0)
outlookMsg.To = emailToList
outlookMsg.Subject = emailSubjectLine
outlookMsg.HTMLBody = emailBodyText
outlookMsg.Send()

 

Failing at first line ? where am I going wrong 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Frequent Contributor

Hi@thouhid1

 

It seems there is some server authentication error may be and would be difficult to debug.

 

But my suggestion would be to use the build In SendMail feature from Testcomplete very easy to use and generally send mail directly from messaging server so need to worry about the authentication.

 

Provided the article just to help you.

https://support.smartbear.com/testcomplete/docs/reference/program-objects/builtin/sendmail.html

 

View solution in original post

3 REPLIES 3
Highlighted
Community Hero

Hi,

 

How your code is executed? Do you start it from TestComplete's IDE or unattended via task scheduler, for example?

Can Outlook be started when you are logged in?

Use test log to figure out what exactly line of code is failing and let us know.

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================
Highlighted
Community Manager

Thank you Alex!

 

Hi@thouhid1! The Community is happy to try solving this, but we need more information from you about the issue.


Sonya Mihaljova
Community and Education Specialist

Learn SmartBear products in a fun and easy way and prove your knowledge!
>>Participate in the TechCorner Challenge today
Highlighted
Frequent Contributor

Hi@thouhid1

 

It seems there is some server authentication error may be and would be difficult to debug.

 

But my suggestion would be to use the build In SendMail feature from Testcomplete very easy to use and generally send mail directly from messaging server so need to worry about the authentication.

 

Provided the article just to help you.

https://support.smartbear.com/testcomplete/docs/reference/program-objects/builtin/sendmail.html

 

View solution in original post

New Here?
Join us and watch the welcome video:
Announcements
Join TechCorner Challenge!
Want a fun and easy way to learn TestComplete? Try solving weekly TechCorner challenges and get into the Leaderboard!


Challenge Status

Get properties of a web page element

See replies!

Compare images using the Region Checkpoint

See replies!

Compare HTML table with Excel file and correct data in Excel file

Participate!

How to execute remote test and obtain results via Test Runner REST API

Participate!
Top Kudoed Authors