I am running a webdriver test to capture screenshots on IE8/ WinXP machine. The code is simple -
WebDriver driver = new InternetExplorerDriver();
driver.get("http://www.google.com/");
File scrFile = ((TakesScreenshot)driver).getScreenshotAs(OutputType.FILE);
FileUtils.copyFile(scrFile, new File("c:\\tmp\\screenshot.png"));
When I run this, a screenshot.png file with size 0KB is generated. I am able to generate screenshots for all other browsers easily, and also on IE8 for Win7. Its failing only for IE8 on WinXP. Any pointers?