Hi Andrei,
I guess, the problem is that some of the objects mentioned in the while(...) statement cannot be found if the login operation fails, and therefore, the appropriate message is posted to the test log. If so, I recommend that you use one of the Wait* methods to make TestComplete wait until the problematic object appears and then check whether the returned object exists - this will allow you to avoid the message. Please see the "Additional Methods Used to Obtain Web Pages Elements" section of the "Working With Web Page Elements" help topic ( http://www.automatedqa.com/support/viewarticle.aspx?aid=6318 ) for more information.