Forum Discussion

anjalirai13's avatar
anjalirai13
New Contributor
7 years ago

Closing Remote Desktop Connection VM Server Unable to create or maximize window object

I am running automation test scripts in Windows 10 with edge Browser. It is unable to maximize the browser window.

 

I read the following article but it did not helped me. 

 

support.smartbear.com/testcomplete/docs/testing-with/running/via-rdp/keeping-computer-unlocked.html. 

 

Is there any other suggestions available

7 Replies

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor

    That you are quoting an article on disconnecting from the remote desktop indicates that you are running into problems with running the scripts on a remote machine.  However, that shouldn't have any impact on browser maximization.  So.... that tells me that... we don't have enough information.

     

    What error are you getting, if any?

    What code are you attempting to execute when the problem occurs?  Please post specific code routine or, if using Keyword tests, a screenshot of the operations being executed?

    How are you triggering your remote execution?

    • anjalirai13's avatar
      anjalirai13
      New Contributor

      While running automation scripts i am using window object to maximize the browser window so that there should not be any problem in verifying the UI Content.. So when i close the remote desktop there is no active window available, At that point script is trying to maximize the browser window while lead to the error.

       

      Unable to create or maximize new browser object: Exception: A window size operation failed because the window is not currently available

      • tristaanogre's avatar
        tristaanogre
        Esteemed Contributor

        This is expected for a closed remote connection.  TestComplete utilizes the UI interface of the Windows environment in order to interact with applications under test.  by closing the remote desktop, the UI is no longer available, hence the error you're getting.

         

        The article you linked in your original message is the best answer to your problem.  I use it regularly.  When I start a test on my remote VM it is part of a batch file in which the first step is to run the script code in that article to transfer the desktop session to the console.

         

        If this isn't working, then there is something different in your environment architecture.  Are you connecting to a VM or to another physical machine?