Page 1 of 1

Solved - Ranorex was unable to start the 32/64 Bit Bridge

Posted: Thu Feb 06, 2014 6:03 pm
by benny28
When I look inside the installed Bin folder:C:\Program Files (x86)\Ranorex 4.1\Bin
I can see 'Ranorex.BitBridge32.exe' but no 'Ranorex.BitBridge64.exe' which the error message is failing to find.

I'm running my test suite on a Win 7 64bit machine (.Net 4.5). The first couple of steps in my test pass.
i.e.
Launch Application
Click on menu bar.

But then when I try to access inside the application the below error is returned.

Code: Select all

[2014/02/06 16:40:53.604][Warn   ][Win32]: The automating and the automated process do not have the same bit width and Ranorex was unable to start the 32/64 Bit Bridge. UI element identification capabilities for controls in that process are limited.
(Detailed error message: Ranorex.RanorexException: Failed to find BitBridge executable 'Ranorex.BitBridge64.exe'.
   at Ranorex.Plugin.CommonControlsFactory.ComputeBridgePath(Boolean x86)
   at Ranorex.Plugin.CommonControlsFactory.RunBridge(Boolean x86, Process& bridgeProcess, String& errorMessage))
The following website provides more information on this technology limitation:
http://www.ranorex.com/support/user-guide-20/technology-instrumentation/general-troubleshooting.html#c3252
I see this error when running my project with MsTest via cmd and VS.
But when I record the sequence via Ranorex Studio it work correctly.

Is there some additional code that Studio implements that I'm missing from my framework created in VS?

Re: Ranorex was unable to start the 32/64 Bit Bridge

Posted: Fri Feb 07, 2014 3:18 pm
by benny28
Reading this troubleshooting page:
http://www.ranorex.com/support/user-gui ... html#c3252

... would suggest 'Enable the 32/64 Bit Bridge in the General Ranorex Settings.'.

Do you have code/method to allow me do this outside of the Studio env (i.e. in a VS project) ?


Reason #2:
The automating and the automated process do not have the same bit width and Ranorex was unable to start the 32/64 Bit Bridge. UI element identification capabilities for controls in that process are limited.

Solution:
Please contact Ranorex support team for further assistance.

Reason #3:
The automating and the automated process do not have the same bit width and the 32/64 Bit Bridge is disabled. UI element identification capabilities for controls in that process are limited.

Solution:
Enable the 32/64 Bit Bridge in the General Ranorex Settings.

Re: Ranorex was unable to start the 32/64 Bit Bridge

Posted: Fri Feb 07, 2014 4:59 pm
by Support Team
Hi benny28,

Yes it is possible to enable the BitBridge in VS.

To enable BitBridge via code use:
Ranorex.Core.Configuration.Current.Plugins.Win32.EnableBitBridge = true;
kind regards,

Markus

Re: Ranorex was unable to start the 32/64 Bit Bridge

Posted: Fri Feb 07, 2014 5:42 pm
by benny28
Thanks Markus

Does this need to called located within a specific method name?
Similar to 'public static void ApplicationRunSpeed()' which I have in a root config file.
Or maybe even within a [Before] hook?

Re: Ranorex was unable to start the 32/64 Bit Bridge

Posted: Mon Feb 10, 2014 5:11 pm
by Support Team
Just add this line of code in your public static int main method
e.g.:

Code: Select all

public static int Main(string[] args)
        {
            // Uncomment the following 2 lines if you want to automate Windows apps
            // by starting the test executable directly
            //if (Util.IsRestartRequiredForWinAppAccess)
            //    return Util.RestartWithUiAccess();

            Keyboard.AbortKey = System.Windows.Forms.Keys.Pause;
            int error = 0;
            Ranorex.Core.Configuration.Current.Plugins.Win32.EnableBitBridge = true;
            try
            {
                error = TestSuiteRunner.Run(typeof(Program), Environment.CommandLine);
            }
            catch (Exception e)
            {
                Report.Error("Unexpected exception occurred: " + e.ToString());
                error = -1;
            }
            return error;
        }
Regards,

Markus (S)

Re: Ranorex was unable to start the 32/64 Bit Bridge

Posted: Wed Feb 12, 2014 12:51 pm
by benny28
Thanks for the response Support Team.

EnablingBitBridge = true; did not resolve my issue so I had to continue digging. I knew that my framework was working correctly on my previous Dev machine. It also worked via Ranorex Studio. But not on my new Dev machine which had a new image (closer to a Live machine).

Anyhow the solution was to reference the x64 DLL's instead of x86 which I had previously referenced (although my previous machines were x64 also). All's good now :)

Re: Solved - Ranorex was unable to start the 32/64 Bit Bridge

Posted: Thu Mar 06, 2014 4:00 am
by DIVKON
Could anyone explain me the steps to reference the x64 DLL's instead of x86?

Re: Solved - Ranorex was unable to start the 32/64 Bit Bridge

Posted: Thu Mar 06, 2014 4:03 am
by DIVKON
Please explain the steps to reference the x64 DLL's instead of x86

Re: Solved - Ranorex was unable to start the 32/64 Bit Bridge

Posted: Mon Mar 10, 2014 4:40 pm
by Support Team
Hi Divkon,

You can find the x64 Ranorex DLL's here:"C:\Program Files (x86)\Ranorex 5.0\Bin\x64".
To reference them you just need to right click on your "References" folder in Ranorex Studio (Projects View) and to select them after you clicked on the "Browse..." button in the ".Net Assembly Browser" tab.

By the way, why do you want to reference the x64 DLL's?

Regards,
Markus

Re: Ranorex was unable to start the 32/64 Bit Bridge

Posted: Mon Jun 30, 2014 11:40 am
by mdgairaud
Support Team wrote:Hi benny28,

Yes it is possible to enable the BitBridge in VS.

To enable BitBridge via code use:
Ranorex.Core.Configuration.Current.Plugins.Win32.EnableBitBridge = true;
kind regards,

Markus

Markus, you make my day... These line of code solved my issue with Chrome and Ranorex :D :D :D
not the same problem as benny28 but the error message was the same.


:mrgreen:

Re: Solved - Ranorex was unable to start the 32/64 Bit Bridge

Posted: Wed Jul 02, 2014 4:13 pm
by Support Team
Hi,

I am glad I was able to help :)!

Regards,
Markus