Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8795191
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T23:21:13+00:00 2026-06-13T23:21:13+00:00

Unable to find/open Firefox Binary – webdriver/robot framework My tests run fine in java

  • 0

Unable to find/open Firefox Binary – webdriver/robot framework

My tests run fine in java and fitnesse. They also run fine when executing them through robot framework with Internet Explorer and Chrome. However when I execute them through Firefox, using ‘new FirefoxDriver()’, I receive the following error:

DEBUG   java.lang.ExceptionInInitializerError 
        at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java: 81) 
Caused by: java.lang.NullPointerException
org.openqa.selenium.firefox.FirefoxBinary.<clinit>(FirefoxBinary.java: 42) 
        ... 183 more 

In the FirefoxBinary and FirefoxDriver classes these lines correspond to the following code:

FirefoxBinary ln42-43 
 private static final String PATH_PREFIX = "/" + 
      FirefoxBinary.class.getPackage().getName().replace(".", "/") + "/"; 

and FirefoxDriver ln 80-82 
public FirefoxDriver(FirefoxProfile profile) { 
    this(new FirefoxBinary(), profile); 
  } 

I have tried setting the path to the Firefox binary in my classpath, pythonpath (used by robotframework) and path. I have also written the following lines of code to try to force the binary to be found:

System.setProperty("webdriver.firefox.bin", "C:\\Program Files (x86)\\Mozilla Firefox\\firefox.exe");
DesiredCapabilities cap = new DesiredCapabilities();
cap.setCapability(FirefoxDriver.BINARY, "C:\\Program Files (x86)\\Mozilla Firefox\\firefox.exe");

I have tried to execute the tests on two computers, my work and home machines. Further I have tried to use a firefox profile created using firefox.exe –p and also by creating one in the java code. I have tried Firefox 6-8. Unfortunately none of these things have worked.

I am also using/have used:
Java 1.6
Selenium 2.9.0/2.13.0
Windows 7

I am unsure if this is related but as a work around I have been trying to get Firefox to run through a remote browser. I have been trying the following code:

rcc = new RemoteControlConfiguration();
rcc.setPort(4447);
rcc.setPortDriversShouldContact(4447);
rcc.setInteractive(true);
rcc.setSingleWindow(true);
rcc.setTimeoutInSeconds(30);
ss = new SeleniumServer(rcc);
ss.start();
DesiredCapabilities cap = new DesiredCapabilities();

cap.setJavascriptEnabled(true);
cap.setBrowserName("firefox");
URL url = new URL ("http://www.google.com/");
driver = new RemoteWebDriver(url,cap);

However when I run the above I get the following error message:

Exception in thread "main" org.openqa.selenium.WebDriverException: Error communicating with the remote browser. It may have died.
Build info: version: '2.13.0', revision: '14794', time: '2011-11-18 17:49:47'
System info: os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '1.7.0'
Driver info: driver.version: Selenium2Driver
    at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:412)

Does anyone have any idea on how to fix either of my problems?

Any help would be greatly appreciated, I feel very stuck on this issue atm. Two days of trying to get Firefox to work when Internet Explorer already does….. It feels as if the world is about to end.

Thanks,
James

EDIT:1

It is possible for me to run Firefox by using selenium-server.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T23:21:13+00:00Added an answer on June 13, 2026 at 11:21 pm

    James, FYI, URL for RemoteWebDriver appears incorrect in post above. Should be something more like “localhost:4444/wd/hub”;? Interestingly, I’m having the opposite problem with Web Driver, having issues starting Firefox via RemoteWebDriver but Firefox runs fine via native FirefoxDriver. IE works fine over remote. – David Dec 4 ’11 at 4:51

    Thanks David!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to insert code for Open Id. I am unable to find article
Why am I getting Unable to find the requested .Net Framework Data Provider when
I have been unable to find any documentation on the .build method in Rails
I have been unable to find any decent documentation on this function. The code
I've been unable to find any info on this, which seems like it could
I have been unable to find any documentation on properly closing database connections in
I've been unable to find a definitive answer to whether custom tags are valid
Simple one but unable to find anything solid on google. I am running Karaf
I keep getting ActivityNotFoundException: Unable to find explicit activity class ... when using Eclipse's
I've searched but was unable to find an existing regex function. Has anybody done

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.