I'm assuming you are using Selenium 1.0. Have you looked at Selenium 2.0 and WebDriver? I found the following and it worked for me. I am assuming that the iframe is named "foo", which will be used to perform typing into the contentEditable iframe.
driver.switchTo().frame("foo");
WebElement editable = driver.switchTo().activeElement();
editable.sendKeys("Your text here");
Many a time, this may not work, and this is because the iframe doesn't have any content. However, on Firefox you can perform the following before "sendKeys" method:
((JavascriptExecutor) driver).executeScript("document.body = '<br>'");
This is required because the iframe has no content by default, which means there's basically nothing to send the keyboard input to. This function call inserts an empty tag, which sets everything up nicely.
Remember to switch out of the frame once you're done (as all further interactions will be within this particular frame):
driver.switchTo().defaultContent();
You can also refer to this link: https://github.com/prabhpreetk/selenium-google-code-issue-archive.git