Forum Discussion

mesg2anil's avatar
mesg2anil
Regular Contributor
14 years ago

How to display two error logs?

Hi...



I have a question on Log.Error usage...

I've mentioned two Log.Error in the script but it display only the first one... how to get the second one in the Log Items?



Example:

    Log.Error "My Error message ONE"

    Log.Error "My Error message TWO"

In the Log Items it displays "Log.Error "My Error message ONE"". How to get "Log.Error "My Error message TWO"" also displayed in the Log Items?

2 Replies

  • Hello Anil,


    Your project may have the Stop on Error option enabled - TestComplete posts the first error message to the test log and then stops the test execution, so your second error message cannot be posted.

    Please try disabling the Stop on error option for your project and check whether all the error messages are posted to the test log.



    To disable the property, please follow the steps below:

    1. Right-click your project in the Project Explorer panel and select Edit | Properties from the context menu.

    2. Choose Playback in the list on the left of the Properties page.

    3. Find the Stop on error option in the options list and disable it.

    For more information on the Stop on error option and on how it affects your tests execution, please see the Project Properties - Playback Options and Stopping Tests on Errors and Exceptions Help topics.


    Please let us know if this does not help.

    Thank you.

  • mesg2anil's avatar
    mesg2anil
    Regular Contributor
    Hi Julia,



    Thank you very much for detailed information!! :)