'The object with the specified attributes does not exist.' error while checking for a CrystalReport
Sorry for the delayed response.
I was playing around with the code and finally, I got a solution for this. I've replaced WaitAliasChild with WaitWinFormsObject method. This is working as expected and my code is successful now.
Here is the new code which fixed the issues.
If Aliases.cwConsole.WaitWinFormsObject("frmCrystalReport", 30000).Exists Then
Thank you very much for your ideas and for helping me to fix the issues. I will be testing the new code and will get back to you if I get any further issues.